plot_periodogram

gammapy.time.plot_periodogram(time, flux, periods, power, flux_err=None, best_period=None, fap=None)[source]

Plot a light curve and its periodogram.

The highest period of the periodogram and its false alarm probability (FAP) is added to the plot, if given.

Parameters
timenumpy.ndarray

Time array of the light curve

fluxnumpy.ndarray

Flux array of the light curve

periodsnumpy.ndarray

Periods for the periodogram

powernumpy.ndarray

Periodogram peaks of the data

flux_errnumpy.ndarray (optional, default=None)

Flux error array of the light curve. Is set to 0 if not given.

best_periodfloat (optional, default=None)

Period of the highest periodogram peak

fapfloat (optional, default=None)

False alarm probability of best_period under a certain significance criterion.

Returns
figFigure

Matplotlib figure