Maximum likelihood estimator of the mean and intrinsic rms of a time-series dataset (based on Keith Horne's avgrmsx). For a detail description of the method, see Keith Horne's lecture on the subject at http://star-www.st-and.ac.uk/~kdh1/ada/ada12.pdf
To install arx, navigate to the folder and in the terminal by using the following command:
pip install -e .
This will make the routine available as a standard python package.
avgrmsx measures the optimally weighted average
where the weights,
where
The routine calculates this optimal average as well as an additional dispersion
where the total variance for the model
import arx
data = [-1,2,1.5]
errors = [0.3,0.5,0.2]
avg,avg_err,rms, rms_err = arx.arx(data,errors)