Giter VIP home page Giter VIP logo

mrexo's Introduction

MRExo

DOI

MRExo is a Python package to jointly model distributions beyond two dimensions. Our updated framework can now simultaneously model up to four observables, while also incorporating asymmetric measurement uncertainties and upper limits in the data.

We build upon the 2-dimensional nonparametric framework utilizing beta density functions as the basis set for density estimation to perform simultaneous density estimation in up to 4-dimensions.

For detailed description of the code please see Kanodia et al. (2019) for the original and Kanodia et al. (2023) for the updated version.

Documentation can be found here.

==================

Installation

Linux/Unix

  1. In the terminal - pip install mrexo

  2. In the terminal - pip install git+https://github.com/shbhuk/mrexo.git -U

OR

  1. In the terminal - pip install git+ssh://[email protected]/shbhuk/mrexo.git -U

OR

  1. In the terminal - git clone https://github.com/shbhuk/mrexo

  2. In the repository directory python setup.py install

The -U is to upgrade the dependencies.

Windows

  1. Install Git - Git for Windows

  2. Install pip - pip for Windows

  3. In cmd or git cmd - pip install git+https://github.com/shbhuk/mrexo.git -U

OR

pip install mrexo

OR

Clone or Download the zip file and then in the repository directory python setup.py install

To sign up for updates, please join the Google Group linked here - https://groups.google.com/forum/#!forum/mrexo

==================

Citation

Guidelines to cite this package can be found here.

The relevant paper can be found on ADS.

==================

mrexo's People

Contributors

gummiks avatar hematthi avatar mrtommyb avatar shbhuk avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

Forkers

mrtommyb hematthi

mrexo's Issues

`Decimal` module raises error while calculating beta distribution for large a, b

For large shape parameters, the current implementation for the beta pdf utilizes gamma functions which tend to blow up to inf when a, b are ~ 150 and larger. For example, GammaFunction(150) ~ 1e260, which pretty quickly crosses machine precision while multiplying/dividing such terms.

if (a>=170) | (b>=170) | (a+b>170):

.... causes error for large datasets where one would like to check for large degree_max.

@JenniferBurt

Check the threshold below which fractional errors -> nans

Because the normal PDF is not being sampled finely enough, if we have measurement errors that are too small then the PDFs are 0 everywhere (giving us nans).

I have set a threshold of 50 sigma at the moment, but need to carefully check if this suffices for period, insolation, etc.. Maybe add some descriptive flags?

Calculating PDF when measurement uncertainty is infinitesimal

The _find_indv_pdf() function tends to zero when the measurement uncertainty is too small. This is especially a problem for the period dimension where the sigmas are typically < 1e-3, 1e-4. This is because at such small sigma values we need to assume only a beta distribution, and not a product of beta and normal.

Therefore we need to figure out how to handle this.. Perhaps an if statement?

Estimating number of weights using Design Effect

In the AIC function we need to estimate the number of weights to penalize the log-likelihood and calculate the AIC.

While we have tried a few different thresholds to calculate weights (nonzero, w > 1e-8), we need to find something more robust

aic = -n_log_lik*2 + 2*(NonZero/DataLength)

Can try this 'Design Effect' Estimated Sample Size method?
https://en.wikipedia.org/wiki/Design_effect#Effective_sample_size

@hematthi

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.