import radvel
import cpsutils.io
import subsaturn.literature

import subsaturn.rv
data = subsaturn.rv.read_subsat2()
instnames = ['hires', 'pfs', 'harps']
data = data[(data.starname == 'K2-32') & data.tel.isin(instnames)]
starname = 'epic205071984_hires+pfs+harps'
ntels = len(instnames)
fitting_basis = 'per tc secosw sesinw k'

bjd0 = 2454833.
nplanets = 3  # number of planets in the system
planet_letters = {1: 'b', 2: 'c', 3: 'd'}
params = radvel.RVParameters(nplanets, basis='per tc e w k')

params['per1'] = 8.992135  # period of 1st planet
params['tc1'] = 2076.91832 + bjd0  # time of inferior conjunction of 1st planet
params['e1'] = 0.00  #
params['w1'] = np.pi / 2.  #
params['k1'] = 5.0  # velocity semi-amplitude for 1st planet
params['per2'] = 20.660155  # same parameters for 2nd planet ...
params['tc2'] = 2128.40674 + bjd0
params['e2'] = 0.00
params['w2'] = np.pi / 2.
params['k2'] = 3.0
params['per3'] = 31.715392  # same parameters for 2nd planet ...
params['tc3'] = 2070.79012 + bjd0
params['e3'] = 0.00
params['w3'] = np.pi / 2.
import os

# Define global planetary system and dataset parameters
starname = 'HD75732_1planet'
nplanets = 1  # number of planets in the system
instnames = [
    'k', 'j'
]  # list of instrument names. Can be whatever you like but should match 'tel' column in the input file.
ntels = len(
    instnames)  # number of instruments with unique velocity zero-points
fitting_basis = 'per tc secosw sesinw k'  # Fitting basis, see radvel.basis.BASIS_NAMES for available basis names
bjd0 = 0.0
planet_letters = {1: 'a'}

# Define prior centers (initial guesses) here.
params = radvel.RVParameters(
    nplanets, basis='per tc e w k')  # initialize RVparameters object

params['per1'] = 14.6521  # period of 1st planet
params['tc1'] = 2074.31  # time of inferior conjunction of 1st planet
params['e1'] = 0.01  # eccentricity of 'per tc secosw sesinw logk'1st planet
params[
    'w1'] = np.pi / 2.  # argument of periastron of the star's orbit for 1st planet
params['k1'] = 70.39  # velocity semi-amplitude for 1st planet

##params['per2'] =  3847.22       # period of 2nd planet
##params['tc2'] = 4441.57          # time of inferior conjunction of 2nd planet
##params['e2'] = 0.19            # eccentricity of 'per tc secosw sesinw logk' 2nd planet
##params['w2'] = np.pi/2.         # argument of periastron of the star's orbit for 2nd planet
##params['k2'] =  31.65          # velocity semi-amplitude for 2nd planet
##
##params['per3'] = 44.3886         # period of 3rd planet
Example #3
0
# number of instruments with unique velocity zero-points
ntels = len(instnames)

# Fitting basis, see radvel.basis.BASIS_NAMES for available basis names
fitting_basis = 'per tc secosw sesinw logk'

bjd0 = 0  # Reference epoch for RV timestamps
# (i.e. this number has been subtracted off your timestamps)

# Map the numbers in the RVParameters keys to planet letters (for plotting and
# tables)
planet_letters = {1: 'b', 2: 'c'}

# Define prior centers (initial guesses) here.
params = radvel.RVParameters(nplanets,
                             basis='per tp e w k',
                             planet_letters=planet_letters)
params['per1'] = 14.3104  # Period of 1st planet
params['tp1'] = 2450020.19  # Time of inferior conjunction of 1st planet
params['e1'] = 0.248  # Eccentricity of 1st planet
params['w1'] = np.pi / 2  # Argument of periastron for 1st planet
params['k1'] = 2.0  # Velocity semi-amplitude for 1st planet
params['per2'] = 2134.76  # Same parameters for 2nd planet ...
params['tp2'] = 2448002.0
params['e2'] = 0.36
params['w2'] = np.pi / 6
params['k2'] = 3.3

time_base = 2453000  # abscissa for slope and curvature terms (should be near
# mid-point of time baseline)
params['dvdt'] = 0.0  # slope: (If rv is m/s and time is days then [dvdt] is