Calculate the Maximum Likelihood Ratio test
The calc_mlr command computes significance using the Maximum Likelihood Ratio test using the change in degrees of freedom and the change in the statistic value.
- delta_dof: the change in degrees of freedom
- delta_stat: change in the statistic value
The Maximum Likelihood Ratio (MLR) test is a model comparison test. Model comparison tests are used to select from two competing models that which best describes a particular dataset. A model comparison test statistic, T, is created from the best-fit statistics of each fit; as with all statistics, it is sampled from a probability distribution p(T). The test significance is defined as the integral of p(T) from the observed value of T to infinity. The significance quantifies the probability that one would select the more complex model when in fact the null hypothesis is correct. A standard threshold for selecting the more complex model is significance > 0.05 (the "95% criterion" of statistics).
The MLR test may be used if:
- the simpler of the two models is nested within the other, i.e., one can obtain the simpler model by setting the extra parameters of the more complex model to default values, often zero;
- the extra parameters have values sampled from normal distributions under the null hypothesis (i.e., if one samples many datasets given the null hypothesis and fits these data with the more complex model, the distributions of values for the extra parameters must be Gaussian);
- those normal distributions are not truncated by parameter space boundaries; and
- the best-fit statistics for each fit individually are sampled from the chi-square distribution.
sherpa> calc_mlr(2, 20)
Calculate the maximum likelihood ratio where the change in degrees of freedom is 2 and the change in statistic is 20.
See the bugs pages on the Sherpa website for an up-to-date listing of known bugs.
- copy_data, dataspace1d, dataspace2d, datastack, delete_data, fake, get_axes, get_bkg_plot, get_counts, get_data, get_data_plot, get_dep, get_dims, get_error, get_quality, get_specresp, get_staterror, get_syserror, group, load_ascii, load_data, load_grouping, load_quality, set_data, set_quality, ungroup, unpack_ascii, unpack_data
- get_filter, load_filter, set_filter
- get_default_id, list_data_ids, list_response_ids
- plot_data, set_xlinear, set_xlog, set_ylinear, set_ylog
- save_error, save_filter, save_grouping, save_quality, save_staterror, save_syserror
- calc_data_sum, calc_data_sum2d, calc_ftest, calc_kcorr, calc_model_sum2d, calc_source_sum2d, get_rate
- contour, contour_data, contour_ratio, get_ratio, get_resid, histogram1d, histogram2d, image_data, rebin