get_combined_flux_maps#

gammapy.estimators.utils.get_combined_flux_maps(estimator, datasets, method='gaussian_errors', reference_model=None, dnde_scan_axis=None)[source]#

Create a FluxMaps by combining a list of flux maps with the same geometry.

This assumes the flux maps are independent measurements of the same true value. The GTI is stacked in the process.

Parameters:
estimatorExcessMapEstimator or TSMapEstimator

Excess Map Estimator or TS Map Estimator

datasetDatasets or list of MapDataset

Datasets containing only MapDataset.

methodstr
  • gaussian_errors :

    Under the gaussian error approximation the likelihood is given by the gaussian distibution. The product of gaussians is also a gaussian so can derive dnde, dnde_err, and ts.

  • distrib :

    Likelihood profile approximation assuming that probabilities distributions for flux points correspond to asymmetric gaussians and for upper limits to complementary error functions. Use available quantities among dnde, dnde_err, dnde_errp, dnde_errn, dnde_ul, and ts.

  • profile :

    Sum the likelihood profile maps. The flux maps must contains the stat_scan maps.

Default is “gaussian_errors” which is the faster but least accurate solution, “distrib” will be more accurate if dnde_errp and dnde_errn are available, “profile” will be even more accurate if “stat_scan” is available.

reference_modelSkyModel, optional

Reference model to use for conversions. Default is None and is will use the reference_model of the first FluxMaps in the list.

dnde_scan_axisMapAxis, optional

Map axis providing the dnde values used to compute the profile. If None, it will be derived from the first FluxMaps in the list. Default is None. Used only if method is “distrib” or “profile”.

Returns:
resultsdict

Dictionary with entries:

  • “flux_maps” : gammapy.estimators.FluxMaps

  • “estimator_results” : dictionary containing the flux maps computed for each dataset.

See also

combine_flux_maps

same method but using directly the flux maps from estimators