Finite exponential families #
This module adds the finite one-parameter exponential-family companion to the Fisher-information and Cramer-Rao layer.
For a finite sample space with positive base weights h and statistic T, the
normalizer is
Z(theta) = sum_x h x * exp(theta * T x)
and the log-partition is A(theta) = log Z(theta). The normalized mass function
is p_theta(x) = h x * exp(theta * T x - A(theta)).
The main results are the finite-sum textbook identities:
A'(theta) = E_theta[T];- the derivative of
E_theta[T]isVar_theta(T), soA''(theta) = Var_theta(T); - the natural-parameter Fisher information equals that same variance.
The Bernoulli witness uses Bool, statistic 1{true}, base weights 1, and
theta = 0, giving A'(0) = 1/2, A''(0) = 1/4, and Fisher information 1/4.
Equations
Instances For
Instances For
Finite exponential-family primitives #
The log-partition function A(theta) = log Z(theta).
Equations
Instances For
The natural-parameter finite exponential-family mass function.
Equations
- FormalSLT.Statistics.ExponentialFamily.finiteExponentialPMF h T theta x = h x * Real.exp (theta * T x - FormalSLT.Statistics.ExponentialFamily.finiteLogPartition h T theta)
Instances For
The natural-parameter derivative of the finite exponential-family mass.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The normalized exponential-family masses sum to one.
Differentiating the finite partition sum termwise.
The normalized expectation is the logarithmic derivative numerator divided by Z.
Log-partition derivative identity.
For a finite exponential family, the derivative of A(theta) is the finite
expectation of the sufficient statistic.
Textbook positive-base form of the log-partition derivative identity.
Curvature and variance #
The derivative of the finite exponential-family mass.
Differentiating the finite mean gives the centered second moment.
The centered second-moment derivative is the finite variance.
Log-partition curvature identity.
For a finite exponential family, differentiating the mean gives the variance of
the sufficient statistic. This is the one-dimensional Hessian identity
A''(theta) = Var_theta(T).
Textbook positive-base form of the log-partition curvature identity.
A named equality form of the curvature identity.
Fisher information connection #
The natural-parameter score is T - E_theta[T].
Fisher information equals exponential-family curvature and variance.
Direct form of I(theta) = A''(theta) for a positive finite exponential family.
Bernoulli natural-parameter witness #
The Bernoulli natural-parameter partition sum is 1 + exp(theta).
At theta = 0, the Bernoulli natural log-partition is log 2.
At theta = 0, the Bernoulli natural-family success probability is 1/2.
A'(0) = 1/2 for the Bernoulli natural family.
At theta = 0, both Bernoulli natural-family atoms have mass 1/2.
At theta = 0, Bernoulli natural-family variance is 1/4.
A''(0) = 1/4 for the Bernoulli natural family.
At theta = 0, Bernoulli natural-family Fisher information is 1/4.
Bernoulli natural-family Fisher information equals variance at theta = 0.
Concrete Bernoulli witness at theta = 0:
A'(0) = 1/2, A''(0) = 1/4, and I(0) = Var(T) = 1/4.