Safe Haskell | None |
---|---|
Language | Haskell2010 |
Implementation of Conway-Maxwell Poisson distributions (CoMPoisson). (https://rss.onlinelibrary.wiley.com/doi/abs/10.1111/j.1467-9876.2005.00474.x) CoMPoisson distributions generalize Poisson distributions with a shape parameter that can concentrate or disperse the underlying Poisson distribution.
Synopsis
- type CoMPoisson = LocationShape Poisson CoMShape
- data CoMShape
- comPoissonLogPartitionSum :: Double -> (Natural # CoMPoisson) -> Double
- comPoissonExpectations :: KnownNat n => Double -> (Int -> Vector n Double) -> (Natural # CoMPoisson) -> Vector n Double
CoMPoisson
type CoMPoisson = LocationShape Poisson CoMShape Source #
The Manifold
of CoMPoisson
distributions. The Source
coordinates of the
CoMPoisson
are the mode $mu$ and the "pseudo-precision" parameter $nu$, such that $mu / nu$ is approximately the variance of the distribution.
A type for storing the shape of a CoMPoisson
distribution.
Instances
Numerics
comPoissonLogPartitionSum :: Double -> (Natural # CoMPoisson) -> Double Source #
Approximates the log-partition function of the given CoMPoisson distribution up to the specified precision.
comPoissonExpectations :: KnownNat n => Double -> (Int -> Vector n Double) -> (Natural # CoMPoisson) -> Vector n Double Source #
Approximates the expectations of functions given the natural parameters of a CoM-Poisson distribution.