pint.utils.akaike_information_criterion
- pint.utils.akaike_information_criterion(model: pint.models.timing_model.TimingModel, toas: pint.toas.TOAs) float [source]
Compute the Akaike information criterion (AIC). The AIC is used for comparing different models for the given dataset.
Given a model with best-fit parameters, the AIC is defined as
AIC = 2*k - 2*ln(L)
where k is the number of free parameters in the model and L is the maximum value of the likelihood for the model.
Given n models with AIC values AIC1, …, AICn, the preferred model is the one that minimizes the AIC value.
If AIC_min is the minimum AIC value, then the i’th model can be said to be exp[AIC_min - AICi] times as probable as the favored model in minimizing information loss.
See, e.g., Burnham & Anderson 2004 for further details.
Unlike the F-test (:function:`~pint.utils.FTest`), the AIC does not require the models to be nested.
See also :function:`~pint.utils.bayesian_information_criterion` for the Bayesian Information Criterion (BIC), a similar quantity used for model comparison. The main practical difference between AIC and BIC is that the BIC more heavily penalizes the number of free parameters.
- Parameters:
model (pint.models.timing_model.TimingModel) – The best-fit timing model
toas (pint.toas.TOAs) – TOAs
- Returns:
aic – The Akaike information criterion
- Return type: