lightkurve.correctors.SFFCorrector.correct

SFFCorrector.correct(centroid_col=None, centroid_row=None, windows=20, bins=5, timescale=1.5, breakindex=None, degree=3, restore_trend=False, additional_design_matrix=None, polyorder=None, sparse=False, **kwargs)

Find the best fit correction for the light curve.

Parameters
centroid_colnp.ndarray of floats (optional)

Array of centroid column positions. If None, will use the centroid_col attribute of the input light curve by default.

centroid_rownp.ndarray of floats (optional)

Array of centroid row positions. If None, will use the centroid_row attribute of the input light curve by default.

windowsint

Number of windows to split the data into to perform the correction. Default 20.

binsint

Number of “knots” to place on the arclength spline. More bins will increase the number of knots, making the spline smoother in arclength. Default 10.

timescale: float

Time scale of the b-spline fit to the light curve in time, in units of input light curve time.

breakindexNone, int or list of ints (optional)

Optionally the user can break the light curve into sections. Set break index to either an index at which to break, or list of indicies.

degreeint

The degree of polynomials in the splines in time and arclength. Higher values will create smoother splines. Default 3.

cadence_masknp.ndarray of bools (optional)

Mask, where True indicates a cadence that should be used.

sigmaint (default 5)

Standard deviation at which to remove outliers from fitting

nitersint (default 5)

Number of iterations to fit and remove outliers

restore_trendbool (default False)

Whether to restore the long term spline trend to the light curve

propagate_errorsbool (default False)

Whether to propagate the uncertainties from the regression. Default is False. Setting to True will increase run time, but will sample from multivariate normal distribution of weights.

additional_design_matrixDesignMatrix (optional)

Additional design matrix to remove, e.g. containing background vectors.

polyorderint

Deprecated as of Lightkurve v1.4. Use degree instead.

Returns
corrected_lcLightCurve

Corrected light curve, with noise removed.