make_lc¶
- tessilator.lc_analysis.make_lc(phot_table, name_lc='target', store_lc=False, lc_dir='lc', cbv_flag=False)[source]¶
Construct the normalised, detrended, cleaned TESS lightcurve.
This is essentially a parent function that performs all the steps in fixing the lightcurve.
The returned product is an array containing the new tabulated lightcurve data for the original (unfiltered) aperture photometry, and (if necessary) another one for the CBV-corrected fluxes (see the ‘cbv_fit_test’ function for more information.)
- Parameters:
- phot_table
astropy.table.Tableordict - The data table containing aperture photometry. Columns must include:“time” -> The time coordinate for each image“mag” -> The target magnitude“(reg/cbv)_oflux” -> The total flux subtracted by the background flux“flux_err” -> The error on flux_corr
- name_lc
str, optional, default=’target’ The name of the file which the lightcurve data will be saved to. The target name
- store_lc
bool, optional, default=False Choose to save the cleaned lightcurve to file
- lc_dir
str, optional, default=’lc’ The directory used to store the lightcurve files if lc_dir==True
- cbv_flag
bool, optional, default=False Choose whether to analyse the lightcurves for CBV-corrected data.
- phot_table
- Returns:
- final_tabs
list A list of tables containing the lightcurve data These are for the original lightcurve, and the cbv-corrected lightcurve if required and it satisfies the criteria from cbv_fit_test.
- norm_flags
list A list of norm_flag values from the detrending algorithm.
- smooth_flags
list A list of smooth_flag values from the detrending algorithm.
- final_tabs