auto p1 = GIGChiPsi!double(params1.chi, params1.psi); auto p2 = GIGChiPsi!double(params2.chi, params2.psi); auto lh0 = properGeneralizedInverseGaussianLikelihood(lambda, p0.eta, p0.omega, sample, weights); auto lh1 = properGeneralizedInverseGaussianLikelihood(params1.lambda, p1.eta, p1.omega, sample, weights); auto lh2 = properGeneralizedInverseGaussianLikelihood(lambda, p2.eta, p2.omega, sample, weights); assert(lh0 <= lh1); assert(lh0 <= lh2); assert(lh2 <= lh1);

See Also

atmosphere.params

Meta

Source

See Implementation

Continue to overload GeneralizedVarianceGammaPDF (atmosphere.pdf.GeneralizedVarianceGammaPDF)

GeneralizedVarianceGammaPDF

Generalized variance-gamma (generalized gamma mixture of normals) PDF. Unstable algorithm.

final
class GeneralizedVarianceGammaPDF : NormalVarianceMeanMixturePDF!T(
T
) if (
isFloatingPoint!T
) {}

Constructors

this
this(T shape, T power, T scale, T beta, T mu)

Examples

auto pdf = new GeneralizedVarianceGammaPDF!double(1.1, 1.1, 0.9, 1.1, 1.1);
auto x = pdf(0.1);
assert(x.isNormal);

import scid.calculus : integrate;
auto result = pdf.integrate(-double.infinity, double.infinity);
assert(fabs(result.value - 1) < result.error);

Meta

NormalVarianceMeanMixturePDF.this (atmosphere.pdf.NormalVarianceMeanMixturePDF.this)

NormalVarianceMeanMixturePDF.this

class NormalVarianceMeanMixturePDF(T)
this
(,,
T mu
,
const(T)[] subdivisions = null
,
T epsRel = 1e-6
,
T epsAbs = 0
)
if (
isFloatingPoint!T
)

Parameters

pdf PDF!T

The PDF to _integrate.

beta T

NVMM scale

mu T

NVMM location

subdivisions const(T)[]

TODO.

epsRel T

(optional) The requested relative accuracy.

epsAbs T

(optional) The requested fabsolute accuracy.

See Also

Meta