ObservationList

class gammapy.data.ObservationList(initlist=None)[source]

Bases: collections.UserList

List of DataStoreObservation.

Could be extended to hold a more generic class of observations.

Methods Summary

append(item)
clear()
copy()
count(item)
extend(other)
index(item, *args)
insert(i, item)
make_mean_edisp(position, e_true, e_reco[, …]) Compute mean energy dispersion.
make_mean_psf(position[, energy, rad]) Compute mean energy-dependent PSF.
pop([i])
remove(item)
reverse()
sort(*args, **kwds)

Methods Documentation

append(item)
clear()
copy()
count(item)
extend(other)
index(item, *args)
insert(i, item)
make_mean_edisp(position, e_true, e_reco, low_reco_threshold=<Energy 0.002 TeV>, high_reco_threshold=<Energy 150. TeV>)[source]

Compute mean energy dispersion.

Compute the mean edisp of a set of observations j at a given position

The stacking is implemented in stack_edisp()

Parameters:

position : SkyCoord

Position at which to compute the mean EDISP

e_true : EnergyBounds

True energy axis

e_reco : EnergyBounds

Reconstructed energy axis

low_reco_threshold : Energy

low energy threshold in reco energy, default 0.002 TeV

high_reco_threshold : Energy

high energy threshold in reco energy , default 150 TeV

Returns:

stacked_edisp : EnergyDispersion

Stacked EDISP for a set of observation

make_mean_psf(position, energy=None, rad=None)[source]

Compute mean energy-dependent PSF.

Parameters:

position : SkyCoord

Position at which to compute the PSF

energy : Quantity

1-dim energy array for the output PSF. If none is given, the energy array of the PSF from the first observation is used.

rad : Angle

1-dim offset wrt source position array for the output PSF. If none is given, the energy array of the PSF from the first observation is used.

Returns:

psf : EnergyDependentTablePSF

Mean PSF

pop(i=-1)
remove(item)
reverse()
sort(*args, **kwds)