Skip to main content

distributions.NormalInverseGaussian

The normal inverse Gaussian law NIG(alpha, beta, delta, mu) for

Usage

Source

distributions.NormalInverseGaussian()

invert_chf (Barndorff-Nielsen, 1997).

With |beta| < alpha and gamma = sqrt(alpha**2 - beta**2), its cumulant generating function is mu s + delta (gamma - sqrt(alpha**2 - (beta + s)**2)). SciPy’s norminvgauss(a, b, loc, scale) is alpha = a / scale, beta = b / scale, delta = scale, mu = loc.

Parameters

alpha: float

Tail heaviness, positive.

beta: float

Skewness, |beta| < alpha.

delta: float

Scale, positive.

mu: float = 0
Location.

Raises

ValueError
If a parameter is out of range.

Examples

>>> from prospicio.distributions import NormalInverseGaussian, invert_chf
>>> d = invert_chf(NormalInverseGaussian(2.0, 0.5, 1.5, 0.3), log2=12)
>>> round(d.mean(), 6)

0.687298

Attributes

Name Description
alpha alpha.
beta beta.
delta delta.
mean The mean.
mu mu.
skewness The skewness.
variance The variance.

alpha

alpha: float


beta

beta.

beta: float


delta

delta: float


mean

The mean.

mean: float


mu

mu.

mu: float


skewness

The skewness.

skewness: float


variance

The variance.

variance: float