Reference / binference.validation.ExactPosterior

binference.validation.ExactPosterior

class binference.validation.ExactPosterior(points, weights, log_density)[source]

Posterior on quadrature nodes over the simplex (K <= 3).

Attributes:
points(n, K) array

Quadrature nodes (fractions).

weights(n,) array

Normalised posterior weights (quadrature weight times density), summing to one.

log_density(n,) array

Unnormalised log posterior density of the fractions at each node (its maximum locates the mode; the weights also carry the node spacing).

__init__(points, weights, log_density)

Methods

__init__(points, weights, log_density)

cov()

Posterior covariance (K, K) of the fractions.

quantile(q, k)

Quantiles of the marginal posterior of fraction k.

Attributes

mean

Posterior mean fractions (K,).

std

Posterior standard deviation of the fractions (K,).

points

weights

log_density

cov()[source]

Posterior covariance (K, K) of the fractions.

property mean

Posterior mean fractions (K,).

quantile(q, k)[source]

Quantiles of the marginal posterior of fraction k.

Parameters:
qfloat or array_like

Probabilities in [0, 1].

kint

Bin index.

property std

Posterior standard deviation of the fractions (K,).