meanfunc
This module provides mean functions for the outputs of the GPRN. Each class
derives from meanFunction and can be added or multiplied to other
meanFunction instances.
meanFunction(*pars)
  Base class for mean functions
Sum(m1, m2)
  
Product(m1, m2)
  
Constant(c)
  
        Bases: meanFunction
A constant mean function
Parameters:
| Name | Type | Description | Default | 
|---|---|---|---|
c | 
          
                float
           | 
          The constant value of the mean function  | 
          required | 
MultiConstant(offsets, obsid, time)
  
        Bases: meanFunction
Contant mean function for multiple instruments
Parameters:
| Name | Type | Description | Default | 
|---|---|---|---|
offsets | 
          
                np.ndarray
           | 
          Values of the between-instrument offsets and the average
     value of the last instrument: [off_1, off_2, ..., avg_n]  | 
          required | 
obsid | 
          
                np.ndarray
           | 
          Indices of observations corresponding to each instrument. These should be one-based: [1, 1, ..., 2, 2, 2, ..., 3]  | 
          required | 
time | 
          
                np.ndarray
           | 
          Observed times. Should be the same size as   | 
          required | 
Linear(slope, intercept)
  
        Bases: meanFunction
A linear mean function, using the mean time as reference
m(t) = slope * (t - mean(t)) + intercept
Parameters:
| Name | Type | Description | Default | 
|---|---|---|---|
slope | 
          
                float
           | 
          The slope of the linear function  | 
          required | 
intercept | 
          
                float
           | 
          The intercept, using mean(t) as reference  | 
          required | 
Parabola(quad, slope, intercept)
  
        Bases: meanFunction
A 2nd degree polynomial mean function
m(t) = quad * t² + slope * t + intercept
Parameters:
| Name | Type | Description | Default | 
|---|---|---|---|
quad | 
          
                float
           | 
          The quadratic term  | 
          required | 
slope | 
          
                float
           | 
          The linear term  | 
          required | 
intercept | 
          
                float
           | 
          The intercept  | 
          required | 
Cubic(cub, quad, slope, intercept)
  
        Bases: meanFunction
A 3rd degree polynomial mean function
m(t) = cub * t³ + quad * t² + slope * t + intercept
Parameters:
| Name | Type | Description | Default | 
|---|---|---|---|
cub | 
          
                float
           | 
          The cubic term  | 
          required | 
quad | 
          
                float
           | 
          The quadratic term  | 
          required | 
slope | 
          
                float
           | 
          The linear term  | 
          required | 
intercept | 
          
                float
           | 
          The intercept  | 
          required | 
Sine(amplitude, period, phase)
  
        Bases: meanFunction
A sinusoidal mean function
m(t) = amplitude * sin(2*pi*t/P + phase)
Parameters:
| Name | Type | Description | Default | 
|---|---|---|---|
amplitude | 
          
                float
           | 
          The amplitude of the sinusoidal function  | 
          required | 
period | 
          
                float
           | 
          The period of the sinusoidal function  | 
          required | 
phase | 
          
                float
           | 
          The phase of the sinusoidal function  | 
          required |