FlareLightCurve

FlareLightCurve is the core class in AltaiPony for light curve de-trending, flare finding, and characterizing.

Functions

detrend_savgol(lc[, window_length, pad, printwl])

Construct a model light curve.

find_flares(flc[, minsep, sigma])

Main wrapper to obtain and process a light curve.

find_iterative_median(flc[, n])

Find the iterative median value for a continuous observation period using flare finding to identify outliers.

flare_model(model, *params)

Flare model wrapper.

generate_fake_flare_distribution(nfake[, ...])

Creates different distributions of fake flares to be injected into light curves.

generate_lightcurve(errorval, a1, a2, ...[, ...])

Generate wild light curves with variability on several timescales.

merge_fake_and_recovered_events(injs, recs)

Helper function that merges the DataFrames containing injected fake flares with the recovered events.

mod_random(x[, d, seed])

Helper function that generates deterministic random numbers if needed for testing.

split_gaps(gaps, splits)

Helper function that splices up a list of tuples into more tuples at values defined by splits, like: ``` gaps = [(0., 20.), (21., 34.), (37., 41.)] splits = [1.5, 14., 39.] result = split_gaps(gaps, splits) >>> result = [(0., 1.5), (1.5, 14.), (14., 20.), >>> (21.0, 34.), (37., 39.), (39., 41.)]

wrap_characterization_of_flares(injrec, flares)

Take injection-recovery results for a data set and the corresponding flare table.

Classes

FlareLightCurve([data, time, flux, flux_err])

Flare light curve class that unifies properties of K2SC-de-trended and Kepler's lightkurve.KeplerLightCurve.

KeplerLightCurve([data, time, flux, flux_err])

Subclass of LightCurve to represent data from NASA's Kepler and K2 mission.

KeplerQualityFlags()

This class encodes the meaning of the various Kepler QUALITY bitmask flags, as documented in the Kepler Archive Manual (Ref.

TessLightCurve([data, time, flux, flux_err])

Subclass of LightCurve to represent data from NASA's TESS mission.

k2sc_lc([data, time, flux, flux_err])

This class is a wrapper for lightkurve (github.com/KeplerGO/lightkurve) so it can call k2sc.

Class Inheritance Diagram

digraph inheritancedc71d63f24 { bgcolor=transparent; rankdir=LR; size="8.0, 12.0"; "BaseTimeSeries" [fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled"]; "QTable" -> "BaseTimeSeries" [arrowsize=0.5,style="setlinewidth(0.5)"]; "FlareLightCurve" [URL="altaipony.flarelc.FlareLightCurve.html#altaipony.flarelc.FlareLightCurve",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="Flare light curve class that unifies properties of ``K2SC``-de-trended and"]; "KeplerLightCurve" -> "FlareLightCurve" [arrowsize=0.5,style="setlinewidth(0.5)"]; "TessLightCurve" -> "FlareLightCurve" [arrowsize=0.5,style="setlinewidth(0.5)"]; "KeplerLightCurve" [fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",tooltip="Subclass of :class:`LightCurve <lightkurve.lightcurve.LightCurve>`"]; "LightCurve" -> "KeplerLightCurve" [arrowsize=0.5,style="setlinewidth(0.5)"]; "LightCurve" [fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",tooltip="Subclass of AstroPy `~astropy.table.Table` guaranteed to have *time*, *flux*, and *flux_err* columns."]; "TimeSeries" -> "LightCurve" [arrowsize=0.5,style="setlinewidth(0.5)"]; "QTable" [fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",tooltip="A class to represent tables of heterogeneous data."]; "Table" -> "QTable" [arrowsize=0.5,style="setlinewidth(0.5)"]; "Table" [fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",tooltip="A class to represent tables of heterogeneous data."]; "TessLightCurve" [fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",tooltip="Subclass of :class:`LightCurve <lightkurve.lightcurve.LightCurve>`"]; "LightCurve" -> "TessLightCurve" [arrowsize=0.5,style="setlinewidth(0.5)"]; "TimeSeries" [fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",tooltip="A class to represent time series data in tabular form."]; "BaseTimeSeries" -> "TimeSeries" [arrowsize=0.5,style="setlinewidth(0.5)"]; }