LightCurve

class rms.LightCurve(times=None, fluxes=None, errors=None, quarters=None, name=None)[source]

Bases: object

Container object for light curves.

Attributes

times_jd Get the times in this light curve in JD.

Methods

delete_outliers()
from_dir(path[, for_stsp]) Load light curve from numpy save files in dir
from_raw_fits(fits_paths[, name]) Load FITS files downloaded from MAST into the LightCurve object.
get_available_quarters() Get which quarters are available in this LightCurve
get_quarter(quarter) Get a copy of the data from within LightCurve during one Kepler quarter.
phases(params)
plot([star, ax, show, phase, plot_kwargs]) Plot light curve.
save_to(path[, overwrite, for_stsp]) Save times, fluxes, errors to new directory dirname in path
split_at_index(index) Split the light curve into two light curves, at index

Attributes Summary

times_jd Get the times in this light curve in JD.

Methods Summary

delete_outliers()
from_dir(path[, for_stsp]) Load light curve from numpy save files in dir
from_raw_fits(fits_paths[, name]) Load FITS files downloaded from MAST into the LightCurve object.
get_available_quarters() Get which quarters are available in this LightCurve
get_quarter(quarter) Get a copy of the data from within LightCurve during one Kepler quarter.
phases(params)
plot([star, ax, show, phase, plot_kwargs]) Plot light curve.
save_to(path[, overwrite, for_stsp]) Save times, fluxes, errors to new directory dirname in path
split_at_index(index) Split the light curve into two light curves, at index

Attributes Documentation

times_jd

Get the times in this light curve in JD.

Returns:

t_jd : ~numpy.ndarray

Julian dates.

Methods Documentation

delete_outliers()[source]
classmethod from_dir(path, for_stsp=False)[source]

Load light curve from numpy save files in dir

classmethod from_raw_fits(fits_paths, name=None)[source]

Load FITS files downloaded from MAST into the LightCurve object.

Parameters:

fits_paths : list

List of paths to FITS files to read in

name : str (optional)

Name of light curve

Returns:

lc : LightCurve

The light curve for the data in the fits files.

get_available_quarters()[source]

Get which quarters are available in this LightCurve

Returns:

qs : list

List of unique quarters available.

get_quarter(quarter)[source]

Get a copy of the data from within LightCurve during one Kepler quarter.

Parameters:

quarter : int

Kepler Quarter

Returns:

lc : LightCurve

Light curve from one Kepler Quarter

phases(params)[source]
plot(star=None, ax=None, show=True, phase=None, plot_kwargs={u'color': u'k', u'lw': 0, u'marker': u'.'})[source]

Plot light curve.

Parameters:

star : ~rms.Star (optional)

Star parameters. Required if phase is True.

ax : ~matplotlib.axes.Axes (optional)

Axis to make plot on top of

show : bool

If True, call matplotlib.pyplot.show after plot is made

phase : bool

If True, map times in JD to orbital phases, which requires that transit_params be input also.

plot_kwargs : dict

Keyword arguments to pass to ~matplotlib calls.

save_to(path, overwrite=False, for_stsp=False)[source]

Save times, fluxes, errors to new directory dirname in path

split_at_index(index)[source]

Split the light curve into two light curves, at index