Normal Conjugate Priors Proofs

Unknown mean and known variance

Property 1: If the independent sample data X = x1, …, xn follows a normal distribution with a known variance φ and unknown mean µ where X|µ N(µ, φ) and the prior distribution is µ ∼ N(µ0, φ0), then the posterior µ|X N(µ1, φ1) where

Posterior normal parameters

Proof: Note that in the proof the proportionality symbol ∝ is used when the previous term is multiplied by a value that doesn’t involve μ, especially when a term not involving µ is added or removed from the expression inside exp.

The prior distribution of the mean parameter is

Prior pdf for mumu pdf part 2

mu pdf part 3The likelihood function is

Likelihood part 1

Likelihood part 2

Likelihood part 3

Using the following equivalence

Posterior variance

and Bayes Theorem it follows that

Posterior part 1

Posterior part 2

Posterior part 3

Posterior part 4

Posterior part 5

This completes the proof since this last formula is proportional to the pdf of the required normal distribution.

Unknown variance and known mean

Property 2: If the independent sample data X = x1, …, xn follow a normal distribution with an unknown variance φ and a known mean µ where X|φ ∼ N(µ, φ) and the prior distribution is φ ∼ Scaled-Inv-χ2(ν, s02) with scale parameter s02 and degrees of freedom ν1 > 0, then the posterior φ|X ∼ Scaled-Inv-χ2(ν1, s12) where

Posterior parameters

s-squared

Proof: The prior distribution of φ is

Prior of phi

Prior of phi continued

The likelihood function is

Likelihood function

Likelihood function continued

By Bayes Theorem

Posterior pdf

Posterior continued

This completes the proof since this last expression is proportional to the pdf of the required scaled inverse chi-square distribution.

Unknown mean and variance

Property A: If the independent sample data X = x1, …, xn follow a normal distribution with an unknown mean µ and variance φ where X|µ, φ ∼ N(µ, φ), then the likelihood function can be expressed as

Normal likelihood function

where ϕ = 1/φ

Proof:

Likelihood function

Likelihood part 2

Likelihood part 3

Likelhood part 4

Likelihood part 5

Since ϕ = 1/φ, it follows that

Likelihood part 6

which is equivalent to the desired result.

Property B: If μ, ϕ has a normal-gamma distribution

Normal-Gamma distribution

then the joint probability function can be expressed as

Joint probability function

Proof: The conditional probability of μ can be expressed as

Conditional probability for mu

Since the marginal probability of ϕ is

Marginal probablity of phi

we see that the joint probability is

Joint probability

Property 3: If the independent sample data X = x1, …, xn follow a normal distribution with an unknown mean µ and variance φ where X|µ, φ ∼ N(µ, φ) and

Normal-Gamma distribution

with ϕ = 1/φ, then the posterior is

Posterior mu, phi

where

Posterior parameters

Posterior parameters continued

Proof: Using Properties A and B

Posterior basic formula

Posterior part 2a

Posterior part 2b

Posterior part 3aPosterior part 3b

Here, we have removed multipliers not involving μ, ϕ from the fourth term in the product and added a multiplier not involving μ, ϕ to the second term. Reordering the terms and using the fact that n1 = n0 + n, yields the following:

Posterior part 4a

Posterior part 4b

Here, the last two terms involve μ, while the first two terms don’t involve μ.

We can reorganize the terms that involve μ as follows:

Mu terms part 1

Mu terms part 2

Mu terms part 3

Mu terms part 4

Mu terms part 5Mu terms part 6

Mu terms part 7

Mu terms part 8

Note that the first term involves μ, while the second term does not. Note too that

Normal pdf

which is the pdf for N(μ1, φ/n1), i.e. f(μ|φ, X)

We can now substitute this result into the original expression for f(μ,φ|X), namely

Posterior part 5a

Posterior part 5bPosterior part 6

But

Sub-formula

and so

Sub-formula 2

Sub-formula 3

Sub-formula 4

It now follows that

Posterior part 7Posterior part 8

Posterior part 9

But the first term in the product represents the gamma pdf for ϕ|X since

Gamma distribution

is equivalent to

Phi pdf

which completes the proof.

Property 4: If the independent sample data X = x1, …, xn follow a normal distribution with an unknown mean µ and variance φ where X|µ, φ ∼ N(µ, φ) and

Normal-Gamma distribution

with ϕ = 1/φ, then the marginal distribution of μ is

Marginal mu t distribution

Proof: If tT(ν0), then the pdf would be

Pdf of t

Thus, it would be sufficient to show that

Restatement of property

Let ϕ = 1/φ0. Then, as we observed at the beginning of the proof of Property 3

Joint pdf

and so

Proof 1

Proof 2

Proof 3

Proof 4

Proof 5

Proof 6

Proof 7

Property 5: Given the premises of Property 4, it follows that for ν0 > 1, the mean of μ is μ0

Proof: Let

By Property 4, the mean of t is 0 for ν0 > 1. Since

Formula for mu

it follows that the mean of μ is

Expectation of mu

References

Clyde, M., Çetinkaya-Rundel M., Rundel, C., Banks, D., Chai, C., Huang, L. (2019) An introduction to Bayesian thinking
https://statswithr.github.io/book/inference-and-decision-making-with-multiple-parameters.html

Walsh, B. (2002) Introduction to Bayesian Analysis
http://staff.ustc.edu.cn/~jbs/Bayesian%20(1).pdf

Leave a Comment