Free Worked Samples
Verified sample problems from CAS MAS-II
Sample 1 · Bayesian & Buhlmann-Straub Credibility Models
Linear Mixed Model Random-Intercept BLUP Shrinkage
In a one-way random-intercept linear mixed model Yij=μ+ui+εij with ui∼N(0,σu2=36) and εij∼N(0,σe2=144), the estimated fixed intercept is μ^=600. Territory i has ni=8 observations with sample mean Yˉi=550. What is the BLUP of the random effect u^i?
- 566.67
- -50.00
- -10.00
- -33.33
Answer: (D) -33.33
Shrinkage Weight & ICC
Compute the LMM shrinkage weight wi=niσu2+σe2niσu2 (where ICC=σu2+σe2σu2=0.2000).
wi=8(36)+1448(36)=0.6667 BLUP Random Effect
Multiply the territory deviation Yˉi−μ^ by wi.
u^i=0.6667(550−600)=−33.33 Second check: Sherman-Morrison matrix form GZi⊤Vi−1(yi−μ^1)=−33.3333 and ICC identity 1+(ni−1)ICCni⋅ICC=0.6667 match.
- A
- Reports the full cluster prediction μ^+u^i instead of the random effect u^i alone.
- B
- Reports the unshrunk fixed-effect residual Yˉi−μ^ without credibility shrinkage.
- C
- Multiplies by the single-observation ICC σu2/(σu2+σe2) instead of accounting for ni.
Sample 2 · Linear Mixed Models (BLUP, REML) & Hierarchical Models
REML vs. ML Variance Component Estimation
A balanced one-way random-intercept model fits G=5 risk groups with m=5 observations per group (N=25 total). The ANOVA decomposition yields within-group mean square MSW=120 and between-group sum of squares SSB=1,920 (so MSB=480). What is the Restricted Maximum Likelihood (REML) estimate σ^u,REML2?
- 360.00
- 52.80
- 96.00
- 72.00
Answer: (D) 72.00
REML Unbiased Degrees of Freedom
REML removes the fixed-intercept degree of freedom (p=1), using MSB=SSB/(G−1).
σ^e,REML2=MSW=120 σ^u,REML2=mMSB−MSW=5480−120=72.00 Comparison with ML
By contrast, unconstrained ML divides SSB by G, causing downward bias.
σ^u,ML2=mSSB/G−MSW=52.80<72.00 Second check: REML score equation ∂ℓREML/∂σu2=−0.00e+00 vanishes at σ^u2=72.00 (excess over ML =MSB/(Gm)=19.20).
- A
- Omits division by group size m when isolating σu2 from MSB−MSW.
- B
- Computes the biased ML estimate (SSB/G−MSW)/m instead of dividing SSB by G−1.
- C
- Fails to subtract MSW from MSB before dividing by m.
Sample 3 · Statistical Learning, Regularization, Trees & MCMC
Bühlmann-Straub Non-Parametric Credibility Estimate
Three risk classes are observed over 2 years with exposures mij and pure premiums Xij: Class 1: (25, $420) and (25, $460); Class 2: (50, $640) and (55, $670); Class 3: (35, $510) and (30, $550). Using the unbiased non-parametric Bühlmann-Straub estimators v^ and a^, what is the credibility-weighted pure premium for Class 1?
- $443.74
- $444.77
- $440.07
- $440.00
Answer: (B) $444.77
Class Means & Process Variance
Compute exposure-weighted class means Xˉi, grand mean Xˉ, and v^=SSW/∑(ni−1).
m=(50,105,65),Xˉ1=440.00,Xˉ=569.09 v^=3(2−1)69,417.58=23,139.19 VHM Estimator & Class 1 Credibility
Compute a^, credibility parameter k^=v^/a^, and Class 1 blend.
a^=220−80.681,728,400.60−2(23,139.19)=12,073.96,k^=a^v^=1.92 Z1=50+1.9250=0.9631,P^1=0.9631(440.00)+0.0369(569.09)=$444.77 Second check: Weighted ANOVA identity SSW+SSB=69,417.58+1,728,400.60=1,797,818.18=SST holds exactly.
- A
- Uses the unweighted average of class means instead of the exposure-weighted grand mean Xˉ.
- C
- Omits the −(R−1)v^ bias correction and exposure factor m−∑mi2/m in a^.
- D
- Assigns full credibility (Z1=1) to Class 1's own weighted mean Xˉ1.
Sample 4 · Bayesian & Buhlmann-Straub Credibility Models
Gamma-Poisson Conjugate Posterior Predictive Variance
Claim frequency Λ per exposure unit has a conjugate Gamma(α=3,β=30) prior (rate parameterization, E[Λ]=α/β). Over E=80 exposure units, k=12 claims are observed. What is the posterior predictive variance Var(Nnew∣k=12) for a future exposure of Enew=100 units?
- 13.64
- 43.33
- 26.03
- 12.40
Answer: (C) 26.03
Conjugate Posterior Update
Update Gamma shape and rate parameters with observed claims k and exposure E.
α′=3+12=15,β′=30+80=110 E[Λ∣k]=11015=0.1364,Var(Λ∣k)=110215=0.001240 Law of Total Variance (Eve's Law)
Combine expected process variance and variance of the conditional mean.
Var(Nnew∣k)=EnewE[Λ∣k]+Enew2Var(Λ∣k)=100(0.1364)+1002(0.001240)=26.03 Second check: Negative Binomial predictive variance r(1−p)/p2 with r=15, p=0.52381 yields 26.0331, matching Eve's Law.
- A
- Reports only the conditional Poisson variance EnewΛ^, omitting parameter uncertainty.
- B
- Computes the prior predictive variance before updating (α,β) with observed claims.
- D
- Reports only Enew2Var(Λ∣k), omitting process variance.