pstat

gdt.core.spectra.fitting.pstat(obs_counts, mod_rates, exposure, back_rates)[source]

Likelihood for Poisson source + known background. The “pstat” statistic from the XSPEC Statistics Appendix.

Parameters:
  • obs_counts (np.array) – The total observed counts

  • mod_rates (np.array) – The model source rates

  • exposure (float) – The source exposure

  • back_rates (np.array) – The background model count rates

Returns:

(float)