Introduction
When claim costs are modeled as normal but both their average level and their variability are uncertain, an update must account for both sources of uncertainty. A normal-inverse-gamma prior provides a conjugate model: after observing conditionally independent normal costs, the posterior for the unknown mean and variance remains normal-inverse-gamma. The calculation depends on more than the sample average; it also uses the observed spread and the distance between the sample average and the prior mean.
The model is useful when a normal approximation is appropriate for the claim-cost quantity being analyzed. A normal distribution can assign positive probability to negative values, so it should not be used uncritically for raw nonnegative severities when that feature is material. The examples below use hypothetical claim-cost measurements, in thousands of dollars, as a modeling approximation.
Model and Prior Parameterization
Let \(X_1,\ldots,X_n\) be conditionally independent observations given an unknown mean \(\mu\) and variance \(\sigma^2\). The sampling model is \(X_i\mid\mu,\sigma^2\sim N(\mu,\sigma^2)\), where the second parameter is the variance. The prior specifies a normal distribution for \(\mu\) conditional on \(\sigma^2\), and an inverse-gamma distribution for \(\sigma^2\).
The conditional prior variance of \(\mu\) is \(\sigma^2/\kappa_0\); a larger \(\kappa_0\) therefore concentrates the prior mean around \(m_0\), relative to the unknown observation variance. The parameters \(\alpha_0\) and \(\beta_0\) control the prior distribution of \(\sigma^2\). Keep the measurement units consistent: if observations are in thousands of dollars, means are in thousands of dollars and variance-related quantities are in squared thousands of dollars.
Sufficient Statistics and Posterior Update
For the normal sampling model, the data enter the update through the sample size \(n\), the sample mean \(\bar X\), and the within-sample sum of squares \(W=\sum_{i=1}^n(X_i-\bar X)^2\). Equivalently, one can use \(n\), \(\sum_i X_i\), and \(\sum_i X_i^2\), since \(W=\sum_i X_i^2-n\bar X^2\). The posterior parameters are:
The posterior mean parameter \(m_n\) is a weighted average of the prior mean and the sample mean. The weight on the observed sample mean is \(n/(\kappa_0+n)\), while the weight on \(m_0\) is \(\kappa_0/(\kappa_0+n)\). The updated inverse-gamma parameter \(\beta_n\) has two data-related additions: within-sample variation, \(W/2\), and a nonnegative adjustment for disagreement between the sample mean and prior mean.
Why the Update Has These Forms
The likelihood kernel, as a function of \(\mu,\sigma^2\), is proportional to \((\sigma^2)^{-n/2}\exp[-\sum_i(X_i-\mu)^2/(2\sigma^2)]\). The joint prior kernel contributes \((\sigma^2)^{-\alpha_0-3/2}\exp[-\{\beta_0+\kappa_0(\mu-m_0)^2/2\}/\sigma^2]\). Combining the exponents uses the identity
This identity follows by writing \(\sum_i(X_i-\mu)^2=W+n(\bar X-\mu)^2\), then completing the square in \(\mu\). The coefficient of \(\mu^2\) is \(n+\kappa_0\), so the center of the completed square is \(m_n=(n\bar X+\kappa_0m_0)/(n+\kappa_0)\). The remaining constant is \(W+\kappa_0n(\bar X-m_0)^2/(\kappa_0+n)\), which yields the two data terms in \(\beta_n\) after division by 2. The power of \(\sigma^2\) increases the inverse-gamma shape by \(n/2\), giving \(\alpha_n\).
Calculate \(n\), \(\bar X\), and \(W\), or obtain \(W\) from the raw sums of observations and squared observations.
Set \(\kappa_n=\kappa_0+n\), then compute the weighted mean \(m_n\).
Add \(n/2\) to \(\alpha_0\), and add both \(W/2\) and the prior-data disagreement adjustment to \(\beta_0\).
Confirm \(\kappa_n>\kappa_0\), \(\alpha_n>\alpha_0\), and \(\beta_n\geq\beta_0\). The mean \(m_n\) must lie between \(m_0\) and \(\bar X\).
Worked Updates
Worked Example: Data Centered at the Prior Mean
A hypothetical insurer models three adjusted claim-cost measurements, in thousands of dollars, as conditionally independent normal observations with unknown \(\mu\) and \(\sigma^2\). The prior parameters are \(m_0=10\), \(\kappa_0=2\), \(\alpha_0=3\), and \(\beta_0=4\). The observed values are 8, 10, and 12. Find the posterior parameters. Name the method and identify a calculation trap.
Method. Use the normal-inverse-gamma conjugate update. The observations give \(n=3\) and \(\bar X=(8+10+12)/3=10\). Their within-sample sum of squares is \(W=(8-10)^2+(10-10)^2+(12-10)^2=4+0+4=8\).
The updated concentration parameter is \(\kappa_n=2+3=5\). The posterior mean parameter is \(m_n=(2(10)+3(10))/5=50/5=10\). The updated shape is \(\alpha_n=3+3/2=4.5\).
The sample mean equals the prior mean, so the disagreement adjustment is \(2(3)(10-10)^2/[2(5)]=0\). Therefore \(\beta_n=4+8/2+0=8\). The posterior parameters are \((m_n,\kappa_n,\alpha_n,\beta_n)=(10,5,4.5,8)\).
Check and trap. The posterior mean remains 10 because both means agree, and \(\beta_n\) has increased by the within-sample contribution \(W/2=4\). A common mistake is to add \(W\), rather than \(W/2\), to \(\beta_0\); that would incorrectly give 12. The update correctly gives \(\beta_n=8\).
Worked Example: Sample Mean Away from the Prior Mean
A hypothetical portfolio has four adjusted claim-cost measurements, in thousands of dollars, of 12, 14, 16, and 18. Assume the same conditional normal model. Its prior parameters are \(m_0=12\), \(\kappa_0=2\), \(\alpha_0=4\), and \(\beta_0=6\). Find the posterior parameters and explain the contribution to \(\beta_n\) from the difference in means.
Method. First calculate the data summaries: \(n=4\), \(\bar X=(12+14+16+18)/4=60/4=15\), and \(W=(12-15)^2+(14-15)^2+(16-15)^2+(18-15)^2=9+1+1+9=20\).
Then \(\kappa_n=2+4=6\), and \(m_n=[2(12)+4(15)]/6=(24+60)/6=14\). The posterior mean is between 12 and 15, as required. Also, \(\alpha_n=4+4/2=6\).
The mean-disagreement contribution is \([2(4)/(2(6))](15-12)^2=(8/12)(9)=6\). The within-sample contribution is \(W/2=20/2=10\). Thus \(\beta_n=6+10+6=22\), and the posterior parameters are \((14,6,6,22)\).
Check and trap. The total increase in \(\beta\) is \(10+6=16\), comprising variation within the sample and disagreement between prior and data means. Omitting the latter term would produce \(\beta_n=16\), which is incorrect. The computed result is 22.
Worked Example: Updating from Raw Sufficient Statistics
For a hypothetical group of four adjusted claim costs, the reported summaries are \(\sum_i X_i=52\) and \(\sum_i X_i^2=702\), with amounts in thousands of dollars. Use a normal-inverse-gamma prior with \(m_0=11\), \(\kappa_0=2\), \(\alpha_0=3\), and \(\beta_0=5\). Find the posterior parameters without treating the reported sum of squares as the within-sample sum of squares.
Method. The sample size is \(n=4\), so \(\bar X=52/4=13\). Convert the raw squared sum to within-sample variation: \(W=\sum_iX_i^2-n\bar X^2=702-4(13^2)=702-676=26\).
The posterior concentration is \(\kappa_n=2+4=6\). The updated mean parameter is \(m_n=[2(11)+4(13)]/6=(22+52)/6=74/6=37/3\), or approximately 12.3333. The shape becomes \(\alpha_n=3+4/2=5\).
The disagreement adjustment is \([2(4)/(2(6))](13-11)^2=(8/12)(4)=8/3\). The within-sample contribution is \(26/2=13\). Therefore \(\beta_n=5+13+8/3=62/3\), or approximately 20.6667. The posterior parameters are \((37/3,6,5,62/3)\).
Check and trap. The mean \(37/3\) lies between the prior mean 11 and sample mean 13, and both variance contributions are nonnegative. A common error is to use \(\sum_iX_i^2=702\) directly as \(W\). The correction subtracts \(n\bar X^2=676\), giving \(W=26\), not 702.
Interpretation and Exam Traps
The update separates two types of information in the data. The sample mean informs the location parameter, while the within-sample sum of squares informs the variance parameter. The disagreement adjustment also increases the posterior variance scale when the observed center differs from the prior center. This is why a sample with little internal spread can still increase \(\beta_n\) substantially if its average is far from \(m_0\).
Several checks help prevent errors:
- Use the stated inverse-gamma convention. Here the density kernel contains \(\exp(-\beta/\sigma^2)\), so \(\beta\) updates by adding half of a sum of squared deviations.
- Distinguish total squared values from within-sample variation. Use \(W=\sum_iX_i^2-n\bar X^2\), not \(\sum_iX_i^2\) alone.
- Include both components in \(\beta_n\). The within-sample term and prior-data disagreement term answer different questions and neither can generally be dropped.
- Keep units consistent. If costs are recorded in thousands of dollars, \(\beta_0\), \(W\), and \(\beta_n\) use squared-thousands units, while \(m_0\) and \(m_n\) use thousands.
- Respect the model assumptions. The result requires conditionally independent observations with a common normal mean and variance. Dependence, changing variances, or a materially unsuitable normal model requires a different likelihood or model.
For this conjugate model, \(n\), \(\bar X\), and \(W\) contain all the information in the observations needed for the posterior update. The update establishes the posterior distributions for \(\mu\) and \(\sigma^2\); it does not by itself specify a future-observation calculation. This material is aligned with the SOA Exam ASTAM (Advanced Short-Term Actuarial Mathematics) syllabus.
Check Your Understanding
For each problem, use the stated normal-inverse-gamma convention and report the posterior parameters in the order \((m_n,\kappa_n,\alpha_n,\beta_n)\).
- A prior has \((m_0,\kappa_0,\alpha_0,\beta_0)=(10,2,3,4)\). Two observations are 9 and 11. Find the posterior parameters. (Answer: \((10,4,4,5)\))
- A prior has \((m_0,\kappa_0,\alpha_0,\beta_0)=(8,1,2,3)\). Three observations are 8, 10, and 12. Find the posterior parameters. (Answer: \((9.5,4,3.5,8.5)\))
- A prior has \((m_0,\kappa_0,\alpha_0,\beta_0)=(10,2,3,2)\). Four observations have sample mean 12 and within-sample sum of squares 20. Find the posterior parameters. (Answer: \((34/3,6,5,44/3)\))
- A prior has \((m_0,\kappa_0,\alpha_0,\beta_0)=(11,3,4,5)\). For five observations, \(\sum_iX_i=60\) and \(\sum_iX_i^2=740\). Find the posterior parameters. (Answer: \((93/8,8,6.5,255/16)\))
- A prior has \((m_0,\kappa_0,\alpha_0,\beta_0)=(10,4,2,3)\). Two observations are 6 and 14. Find the posterior parameters and state why the prior-data disagreement contribution to \(\beta_n\) is zero. (Answer: \((10,6,3,19)\); the sample mean equals the prior mean.)