astro
Utility functions for common astronomical calculations
- alderaan.utils.astro.bin_data(time, data, binsize, bin_centers=None)
Bin a 1D timeseries data array
If bin_centers is not provided, bins will be linearly spaced between (time.min(),time.max())
- Parameters:
time (ndarray) – time values
data (ndarray) – corresponding data to be binned
binsize (float) – bin size for output data, in same units as time
bin_centers (optional) – pre-defined bin centers
- Returns:
- a tuple containing:
time_binned (array-like)
data_binned (array-like)
- Return type:
tuple
- alderaan.utils.astro.estimate_transit_depth(p, b)
Calculate approximate transit depth following Mandel & Agol (2002)
- Parameters:
p (array-like) – planet-to-star radius ratio Rp/Rstar
b (array-like) – impact parameter
- Returns:
transit depth
- Return type:
array-like
- alderaan.utils.astro.predict_tc_error(ror, b, T14, texp, sigma_f)
Predict uncertainty on mid-transit time See Carter+2008
- Parameters:
ror (planet-to-star radius ratio)
b (impact parameter)
T14 (first-to-fourth contact transit duration)
texp (exposure time (in same units as T14))
sigma_f (photometric error on flux)