compute_flux_doubling#

gammapy.stats.compute_flux_doubling(flux, flux_err, coords, axis=0)[source]#

Compute the minimum characteristic flux doubling and halving over a certain coordinate axis for a series of measurements.

Computing the flux doubling can give the doubling time in a lightcurve displaying significant temporal variability, e.g. an AGN flare.

The variable is computed as:

\[doubling = min(\frac{t_(i+1)-t_i}{log_2{f_(i+1)/f_i}})\]

where f_i and f_(i+1) are the fluxes measured at subsequent coordinates t_i and t_(i+1). The error is obtained by propagating the relative errors on the flux measures.

Parameters:
fluxQuantity

The measured fluxes.

flux_errQuantity

The error on measured fluxes.

coordsQuantity

The coordinates at which the fluxes are measured.

axisint, optional

Axis along which the value is computed.

Returns:
doubling_dictdict

Dictionary containing the characteristic flux doubling, halving and errors, with coordinates at which they were found.