You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Method to calculate the penalty term which is used in the chi squared calculation. This takes into account any systematics which are associated with the fit.
This is the class described in snoplusuk#4, and provides the functionality required
by snoplusuk#2, snoplusuk#5 and snoplusuk#6, although the structure is modified. As such this pull request
fixessnoplusuk#2, closessnoplusuk#4, resolvessnoplusuk#5 and fixessnoplusuk#6.
The module contains three functions to calculate chi squared for a number given
number of observed events and number of expected events. The forms of chi
squared calculation included are Pearson's, Neyman's and the Poisson Likelihood
chi squared.
The module also adds the `ChiSquared` class that acts as a calculator for a
given `form` of chi squared calculation. It can also be initialised with
penalty term information via the keyword argument `penalty_term`. Or this can
be specified when calling the `get_chi_squared` method. The method takes two 1D
numpy arrays, representing the observed (or "data") spectrum and the expected
(or "MC") spectrum, as arguments and iterates over the array, calculating the
chi squared for each bin using the appropriate function, and adding a penalty
term if required. The method returns the total chi squared comparing the two
spectra.
Method to calculate the penalty term which is used in the chi squared calculation. This takes into account any systematics which are associated with the fit.
Will form the
get_penalty_term
method in #4The text was updated successfully, but these errors were encountered: