stochastic-rs-copulas
Bivariate, multivariate, and empirical copulas
Dependence modelling: Archimedean and extreme-value families in two dimensions, vine and nested constructions in higher dimensions.
What is in it
- Bivariate (
BivariateExt) — Clayton, Frank, Gumbel, Joe, AMH, Plackett, FGM, Galambos, Hüsler-Reiss, Marshall-Olkin, Student-t and independence. Each ships cdf, pdf, conditional inverse, Kendall's tau and a sampler. - Multivariate (
MultivariateExt) — Gaussian, Student-t, C-vine, D-vine, R-vine and nested Archimedean copulas. - Empirical — pseudo-observations and the empirical copula.
- Process coupling — drive two stochastic processes through a copula.
Every multivariate sampler has a sample_seeded(n, seed) counterpart when
the draw needs to be reproducible.
Usage
use Clayton;
use BivariateExt;
let mut c = Clayton ;
let u = c.sample?; // Array2<f64>, shape (10000, 2)
let v = c.sample_with_seed?; // reproducible
Multivariate constructions take a tree of PairCopula variants:
use CVine;
use PairCopula;
let cv = new?;
let draws = cv.sample_seeded;
Part of stochastic-rs
This crate is one of the sub-crates of stochastic-rs. Most users should depend on the umbrella crate, which re-exports everything:
[]
= "2.6"
Depend on stochastic-rs-copulas directly only when you want this slice and nothing else.
- Documentation: stochastic.rust-dd.com
- API reference: docs.rs/stochastic-rs-copulas
License
MIT