Fournax

class dorado.Fournax(name, epoch=None, period=None)[source] [edit on github]

Bases: Target

The Fournax class extends the TOI target class to provide a consistent simple, yet robust interface to targets with regular or semi-regular photometric variability for the purposes of lightcurve/timeseries fourier analysis.

Fournax is an abbreviation of Fourier numerical astronomy extension, its name is a backronym styled to match the constellation ‘fornax’.

Attributes:
name: str

name of target in string format.

epoch: float or astropy.Time

Epoch for the targets ephemeris of which the theoretical times of extrema will be extrapolated from.

period: float

The period between extrema of interest corresponding to the ephemeris epoch given.

Methods Summary

OMinusC(fi)

OMinusC takes observed time(s) of max light for a repeating variable star and ephemeris data and returns O-C values as well as the corresponding cycle.

analyze(fi[, graphical, terms, s])

analyze is a wrapper function that runs a pipeline of analysis functions in the Fournax target class, self.superfit, self.tomlFind, self.OMinusC, and self.fourFind Parameters ---------- filter: string filter string of filter to perform analysis on.

fourFind(fi[, fitted])

fourFind locates distinct peak structures in a Fourier power spectra generated via a photometric timeseries stored within self.ts. Parameters ---------- filter: string filter string of filter to perform analysis on. fitted: boolean default is True. Controls whether fitted timeseries or raw timeseries is used for analysis.

smooth(x[, window_len, window])

smooth the data using a window with requested size. This method is based on the convolution of a scaled window with the signal. The signal is prepared by introducing reflected copies of the signal (with the window size) in both ends so that transient parts are minimized in the begining and end part of the output signal. input: x: the input signal window_len: the dimension of the smoothing window; should be an odd integer window: the type of window from 'flat', 'hanning', 'hamming', 'bartlett', 'blackman' flat window will produce a moving average smoothing. output: the smoothed signal example: t=linspace(-2,2,0.1) x=sin(t)+randn(len(t))*0.1 y=smooth(x) see also: numpy.hanning, numpy.hamming, numpy.bartlett, numpy.blackman, numpy.convolve scipy.signal.lfilter TODO: the window parameter could be the window itself if an array instead of a string NOTE: length(output) != length(input), to correct this: return y[(window_len/2-1):-(window_len/2)] instead of just y. https://scipy-cookbook.readthedocs.io/items/SignalSmooth.html 2017-07-13 (last modified), 2006-10-31 (created) Section author: Unknown[1], GaelVaroquaux, Unknown[142], Unknown[143], Unknown[144], Unknown[145], Unknown[146], Unknown[147], WesTurner, Christian Gagnon, clecocel.

superfit(fi, terms, s)

superfit takes a raw timeseries and performs a multistep smoothed fit of the data which includes a spline fit tailored with the curvature of knots from a spline fit of a Fourier fit. The result is then expanded and then convoluted with a 'blackman' window function. Parameters ---------- x, y: array timeseries arrays to be fit terms: int terms to retain in the fourier fit. s: int new data array size Returns ------- X, Y: array The superfit timeseries arrays.

tomlFind(fi[, fitted])

tomlFind locates the distinct times of max light in a photometric timeseries stored in self.ts Parameters ---------- filter: string filter string of filter to perform analysis on. fitted: boolean default is True. Controls whether fitted timeseries or raw timeseries is used for analysis.

Methods Documentation

OMinusC(fi)[source] [edit on github]

OMinusC takes observed time(s) of max light for a repeating variable star and ephemeris data and returns O-C values as well as the corresponding cycle.

Returns:
cycle: float, list, or array

The cycle corresponding to the time(s) of max light

OmC: float, list, or array

The O-C value for the time(s) of max light

analyze(fi, graphical=True, terms=None, s=None)[source] [edit on github]

analyze is a wrapper function that runs a pipeline of analysis functions in the Fournax target class, self.superfit, self.tomlFind, self.OMinusC, and self.fourFind Parameters ———- filter: string

filter string of filter to perform analysis on.

graphical: boolean

default is True. Controls whether or not graphical results are output (NOTE:: parameter currently not in use)

fourFind(fi, fitted=True)[source] [edit on github]

fourFind locates distinct peak structures in a Fourier power spectra generated via a photometric timeseries stored within self.ts. Parameters ———- filter: string

filter string of filter to perform analysis on.

fitted: boolean

default is True. Controls whether fitted timeseries or raw timeseries is used for analysis.

smooth(x, window_len=11, window='hanning')[source] [edit on github]

smooth the data using a window with requested size. This method is based on the convolution of a scaled window with the signal. The signal is prepared by introducing reflected copies of the signal (with the window size) in both ends so that transient parts are minimized in the begining and end part of the output signal. input: x: the input signal window_len: the dimension of the smoothing window; should be an odd integer window: the type of window from ‘flat’, ‘hanning’, ‘hamming’, ‘bartlett’, ‘blackman’

flat window will produce a moving average smoothing.

output: the smoothed signal example: t=linspace(-2,2,0.1) x=sin(t)+randn(len(t))*0.1 y=smooth(x) see also: numpy.hanning, numpy.hamming, numpy.bartlett, numpy.blackman, numpy.convolve scipy.signal.lfilter TODO: the window parameter could be the window itself if an array instead of a string NOTE: length(output) != length(input), to correct this: return y[(window_len/2-1):-(window_len/2)] instead of just y. https://scipy-cookbook.readthedocs.io/items/SignalSmooth.html 2017-07-13 (last modified), 2006-10-31 (created) Section author: Unknown[1], GaelVaroquaux, Unknown[142], Unknown[143], Unknown[144], Unknown[145], Unknown[146], Unknown[147], WesTurner, Christian Gagnon, clecocel

superfit(fi, terms, s)[source] [edit on github]

superfit takes a raw timeseries and performs a multistep smoothed fit of the data which includes a spline fit tailored with the curvature of knots from a spline fit of a Fourier fit. The result is then expanded and then convoluted with a ‘blackman’ window function. Parameters ———- x, y: array

timeseries arrays to be fit

terms: int

terms to retain in the fourier fit.

s: int

new data array size

Returns

X, Y: array

The superfit timeseries arrays.

tomlFind(fi, fitted=True)[source] [edit on github]

tomlFind locates the distinct times of max light in a photometric timeseries stored in self.ts Parameters ———- filter: string

filter string of filter to perform analysis on.

fitted: boolean

default is True. Controls whether fitted timeseries or raw timeseries is used for analysis.