sysrem.py - CBV routines

Routines for computing the co-trending basis vectors (CBVs) for each K2 campaign using the SysRem algorithm.

everest.missions.k2.sysrem.GetCBVs(campaign, model='nPLD', clobber=False, **kwargs)

Computes the CBVs for a given campaign.

Parameters:
  • campaign (int) – The campaign number
  • model (str) – The name of the everest model. Default nPLD
  • clobber (bool) – Overwrite existing files? Default False
everest.missions.k2.sysrem.GetChunk(time, breakpoints, b, mask=[])

Returns the indices corresponding to a given light curve chunk.

Parameters:b (int) – The index of the chunk to return
everest.missions.k2.sysrem.GetStars(campaign, module, model='nPLD', **kwargs)

Returns de-trended light curves for all stars on a given module in a given campaign.

everest.missions.k2.sysrem.SysRem(time, flux, err, ncbv=5, niter=50, sv_win=999, sv_order=3, **kwargs)

Applies SysRem to a given set of light curves.

Parameters:
  • time (array_like) – The time array for all of the light curves
  • flux (array_like) – A 2D array of the fluxes for each of the light curves, shape (nfluxes, ntime)
  • err (array_like) – A 2D array of the flux errors for each of the light curves, shape (nfluxes, ntime)
  • ncbv (int) – The number of signals to recover. Default 5
  • niter (int) – The number of SysRem iterations to perform. Default 50
  • sv_win (int) – The Savitsky-Golay filter window size. Default 999
  • sv_order (int) – The Savitsky-Golay filter order. Default 3