Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a log-logistic distribution fitting #106

Open
monocongo opened this issue Apr 23, 2018 · 6 comments
Open

Add a log-logistic distribution fitting #106

monocongo opened this issue Apr 23, 2018 · 6 comments

Comments

@monocongo
Copy link
Owner

It's been shown that a log-logistic distribution fitting is optimal for SPEI calculations. Let's add this to complement the gamma and Pearson III distribution fittings we already have available. This may already be available in some form in statsmodels or SciPy, we should investigate there before rolling our own.

@monocongo
Copy link
Owner Author

Apparently, the log-logistic distribution is also referred to as the Fisk distribution, available within SciPy.

@monocongo
Copy link
Owner Author

Related to issue #190.

@Emmadd
Copy link

Emmadd commented Aug 26, 2021

I created a draft (there are some minor issues) pull request for a Fisk implementation in #440
However, looking into the R code some more, I realised that the R SPEI package uses a generalised logistic distribution, more similar to genlogistic in SciPy than to Fisk. The distributions might be similar when c=-/k, but I am not certain.

@monocongo
Copy link
Owner Author

Thanks for your work on this @Emmadd

Is it useful for us to also provide a generalized logistic distribution? I'd like to include it if so, but only if truly useful as it will add maintenance cost, and this project is already due significant maintenance, we don't want to add even more technical debt.

@Emmadd
Copy link

Emmadd commented Aug 26, 2021

I don't think so. But if someone with more statistical knowledge thinks otherwise it would be good to know.

@Emmadd
Copy link

Emmadd commented Sep 2, 2021

After some further investigation it seems the python SciPy Fisk option is the better one to use. The genlogistic in python is a special generalised logistic distribution, not THE generalised logistic distribution that R uses, which resembles Fisk. So #440 can be continued.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants