WStatCountsStatistic#
- class gammapy.stats.WStatCountsStatistic[source]#
Bases:
CountsStatistic
Class to compute statistics for Poisson distributed variable with unknown background.
- Parameters:
- n_onint
Measured counts in on region.
- n_offint
Measured counts in off region.
- alphafloat
Acceptance ratio of on and off measurements.
- mu_sigfloat
Expected signal counts in on region.
Attributes Summary
Approximate error from the covariance matrix.
Known background computed alpha * n_off.
Excess.
Stat value for best fit hypothesis.
Stat value for null hypothesis, i.e. mu_sig expected signal counts.
Methods Summary
Attributes Documentation
- error#
Approximate error from the covariance matrix.
- n_bkg#
Known background computed alpha * n_off.
- n_sig#
Excess.
- stat_max#
Stat value for best fit hypothesis.
i.e. expected signal mu = n_on - alpha * n_off - mu_sig.
- stat_null#
Stat value for null hypothesis, i.e. mu_sig expected signal counts.
Methods Documentation
- info_dict()[source]#
A dictionary of the relevant quantities.
- Returns:
- info_dictdict
Dictionary with summary info.
- sum(axis=None)[source]#
Return summed CountsStatistics.
- Parameters:
- axisNone or int or tuple of ints, optional
Axis or axes on which to perform the summation. Default, axis=None, will perform the sum over the whole array.
- Returns:
- stat
CountsStatistics
The summed stat object.
- stat
- classmethod __new__(*args, **kwargs)#