Generalized Chi-squared distribution

Does anybody know some attempt to implement the Generalized Chi-squared distribution in Julia? (First I looked for it in Distributions.jl, but I have not found it there or anywhere else.)

Not that I’m aware of, but depending on what you want to use it for, a sampler should be easy to implement! If you want to go down the route of copying the R code to create a new Univariate Distribution I’m sure it would be much appreciated by the package maintainers :slightly_smiling_face:

1 Like

Thanks. The R library seems to depend on C++ code that is not easy for me, and is GPL-licensed, so maybe it’s not a good choice. The Python library is MIT-licensed, but it seems also dependent on C++ and only implements the CDF, if I’m not mistaken. The Matlab library, which is also MIT-licensed, might be another option, I think.

1 Like

If the Matlab is MIT licensed, I’d definitely go for that! You can also try out the Matlab-to-Julia transpiler to make your job a little bit easier, although do note that it’s pretty rough and only gives a “first draft” that you’ll probably have to edit.

2 Likes

I have followed your suggestion:

2 Likes