MNGuenther / allesfitter

allesfitter is a convenient wrapper around the packages ellc (light curve and RV models), dynesty (static and dynamic nested sampling) emcee (Markov Chain Monte Carlo sampling) and celerite (Gaussian Process models).
MIT License
60 stars 36 forks source link

Derived_params.csv companion masses are printed incorrectly #33

Closed MNGuenther closed 3 years ago

MNGuenther commented 3 years ago

In the derived_params.csv table, the M_earth and M_jup values are printed incorrectly. (All other values, especially the fitted ones, are correct.)

MNGuenther commented 3 years ago

This was a minor bug introduced by a recent update in 1.2.4, where allesfitter's deriver.py introduced separate mass calculations to differ double-line binaries (fitting for K and q) and single-line binaries / exoplanets (fitting for K only). The parameter q is set to 1 by default and ignored for single-line binaries / exoplanets. The if-else statement to differ those cases was incorrect and q=1 was accidentally used to compute the masses for single-line binaries / exoplanets, meaning the printed result was merely the host mass. All fixed now.

gdransfield commented 3 years ago

Hi Max!

For me this problem persists, despite having the most recent version installed. I'm running a 3-planet fit and all derived masses come up as the stellar mass.

I've installed the most recent version from pypi and compared the files with what's currently on Github and it's a match, Not sure what to do!

Cheers, George

ns_derived_corner

MNGuenther commented 3 years ago

This only happens for v1.2.4. Any previous or later version does not have this issue.