[ANN] Copulas.jl : A fully `Distributions.jl`-compliant copula package

I am happy to annouce here that version 0.1.17 is out!

The package has seen a lot of (non-breaking) changes:

  • The documentation has largely improved, including some examples of uses with Turing, some SklarDist examples, etc…
  • Several functionalities were added to Archimedean copulas, including the (never-implemented-before-in-OSS) general WilliamsonCopula, that uses the Williamson d-transform to sample from every archimedean. The package is now able to sample from every archimedean copulas.
  • PlackettCopula, FGMCopula, GumbelBarnettCopula, InvGaussianCopula, added by courtesy of Santymax98, with top-of-the-line algorithms.
  • When needed matrix sampler are provided (faster sampling).
  • A lot of bug were fixed and a lot of tests were added.

Check out the rest on Copulas.jl’s github, and do not hesitate to open an issue if you want to discuss

4 Likes

Hello,

Thank you for this nice package. A detail: AFAIK, the wording is Frank copula, not Franck.

1 Like

Oups. Edit: It seems to be have been corrected to Frank in the package already, only here I cannot write it correctly :slight_smile:

2 Likes

Hello!
I’m soo glad to see this effort on improving Julia’s environment with copulas, thanks for that!

Do you have any idea on when the project will embrace Nested Copulas (fitting parameters and rand numbers generation)?

And thanks again for the effort!

2 Likes

Thanks for the nice message, this is appreciated :slight_smile: If you use it do not hesitate to star the package on our github page this is always warming for us :heartbeat:

Welcome to discourse BTW !

Concerning nested archimedean copulas, this should come quite soon, we completely refactored the internals of archimedean generators to allow greater generality and simplify future extensions : Liouville copulas (there is already a PR) and of course hierarchical models, archimedeans and liouville. This will allow an unprecetended generality of the architecture, since you will be able to input and nest your own generators without any issue (while in R only clayton and gumbel are availiable… and no nesting of diffrent families…).

If you meant Vines copulas, then this is a bit harder to do but it is also in our plans, maybe longer-term… If you want to do it or propose an implementation plan, do not hesitate !

Cheers

3 Likes

Nice! I’m excited to start using it as soon as available!
My requirement is for partially-nested archimedean copulas (2 layers, many dimensions on the second layer), both fitting data to extract the parameters and later generating random numbers (not that I might be any technical at all, but I’ve read the dissertation from Jan Hofert (Sampling Nested Archimedean Copulas
with Applications to CDO Pricing
) and it seems he got to a much faster and still reliable algorithm for generating nested-copula random numbers, which seems to be implemented in the R copula package, so it felt amazing to have this in plain Julia).

The generation part seems to be achievable with the DatagenCopulaBased.jl, at least for what I require.

Thanks for the answer and hope to start using Copulas.jl soon!

Yes DatagenCopulaBased might have you covered for the generation part of these models, if you only require “standard” families of generators like clayton or gumbel, I totally forget about it you are right. Edit: In fact what they have is chains of archimedeans, which is not the same at all. For Nested Archimedeans you are for the moment out of luck, I’m sorry…

Maybe will be done some day :slight_smile:

1 Like

Super cool package. I have gone through your roadmap, and I note you have stated you may implement vines. That is a relatively big undertaking, but it’d be amazing!

1 Like

Yep, It’s the plan. The goal is to do a full native Julia re-implementation and not only to wrap the (amazing) C++ vinecopulib from Nagler & al. More precisely:

  • The methods needed for each bivariate copula are already there
  • A bit of machinery is still needed to construct a vine, and sample from it.
  • Dißmann’s algorithm needs to be implemented to fit a vine.

The upside of a full Julia implementation is type agnosticism and cooperation with the broader ecosystem of course :slight_smile:
But this is a lot of work, if you want to undertake it you can :innocent:

2 Likes

Fantastic, I might lend you a hand if I get the chance to. I am hoping one of my grant applications get funded, let’s see! I am very interested in graphical models for multivariate EVT.

1 Like

Tuuut Tuuut !

A new version 0.1.21 was published, including numerous bug fixes and new functionalities. This is due to the JOSS review of the package, that is now published there Journal of Open Source Software: Copulas.jl: A fully Distributions.jl-compliant copula package

Among others:

  • The docs largely improved, including an example section that was not there before and features a few nice use-cases.
  • A new logo thanks to @lmiq
  • Many bugs were solved
  • Moar archimedean generators
  • Moar copulas.

Do not hesitate to check it out :slight_smile:

15 Likes

:rocket: Copulas.jl v0.1.24 Released! :rocket:

We’re excited to announce the release of version 0.1.24 of Copulas.jl! This version includes critical updates and improvements that enhance the package’s functionality and ease of use.

What’s New:

  • :tada: Bivariate Extreme Value Copulas Added: Thanks to the contributions from @Santymax98, we’ve expanded our collection of copulas to include Bivariate Extreme Value Copulas, a significant addition for modeling extreme events.

  • :wrench: Documentation Improvements: Several issues were fixed, ensuring that the documentation is clearer and more accurate, particularly in relation to extreme value copulas.

  • :hammer_and_wrench: Infrastructure Upgrades: Updated Julia actions for setup and caching, ensuring a smoother experience for users and developers alike.

  • :memo: Minor Fixes: Various small but essential fixes, such as removing unnecessary URLs and spaces in the code, were implemented to keep the codebase clean and efficient.

Thanks to everyone who contributed to this release, especially @lrnv and @Santymax98.

:chart_with_upwards_trend: Don’t miss out on exploring the new features and improvements. Update now and check out the latest version of Copulas.jl!

Let us know what you think, and as always, contributions and feedback are welcome! :blush:

6 Likes