Tutorials › CAS Exam 8 - Advanced Ratemaking › Treatment Contrasts for Categorical Rating Factors

CAS Exam 8 · Estimation and Relativity Interpretation · Tutorial 183 of 989

Treatment Contrasts for Categorical Rating Factors

Interpret treatment-coded GLM coefficients relative to the omitted level, reconstruct fitted rates, and see why changing the reference changes the reported coefficients without changing predictions.

Intermediate 10 min read

What You'll Learn

  • Specify a treatment-coded model for a rating factor with multiple levels.
  • Interpret each coefficient relative to the omitted reference level.
  • Recover fitted rates and expected counts from an intercept, coefficients, and exposure.
  • Re-express coefficients when a different level is chosen as the reference.
  • Distinguish conditional GLM effects from raw portfolio averages.
  • Identify common errors in interpreting log-link coefficients.

Why the Omitted Level Matters

A categorical rating factor may have several levels, such as vehicle class, territory, or building construction. A model needs a numerical representation of those levels, but its reported coefficients depend on the representation chosen. With treatment coding, one level is omitted from the indicator columns and serves as the reference. Every included coefficient describes its level relative to that reference, conditional on the other model terms.

The omission is a coding choice, not an assertion that the reference level is average, risk-free, or otherwise special. Choosing a different reference changes the intercept and the displayed coefficients. If the model is re-expressed correctly, it does not change the fitted rate for any risk.

Definition: Suppose a categorical factor has \(K\) levels and level 1 is designated as the reference. Treatment coding uses an indicator \(I_{ij}=1\) when observation \(i\) is in level \(j\), and \(0\) otherwise, for \(j=2,\ldots,K\). Under a log-link rate model, the factor's contribution to the linear predictor is \(\beta_0+\sum_{j=2}^K\beta_j I_{ij}\), with other predictors added as specified by the model. The reference level has all these indicators equal to zero; \(\beta_j\) is the log-rate difference between level \(j\) and the reference, holding other predictors fixed.

Model and Coefficient Interpretation

For concreteness, consider a hypothetical claim-frequency model. Let \(N_i\) be the claim count for observation \(i\), and let \(e_i\) be its exposure in policy-years. Assume a Poisson GLM conditional on the predictors, with mean \(\mu_i=E[N_i\mid\text{predictors}]\), log link, and exposure offset:

$$ N_i\mid\text{predictors}\sim\operatorname{Poisson}(\mu_i), \qquad \log(\mu_i)=\log(e_i)+\beta_0+\sum_{j=2}^{K}\beta_j I_{ij}. $$

This specification assumes a positive exposure and a conditional mean proportional to exposure. The offset coefficient is fixed at 1. The Poisson assumption supplies a particular count distribution; the treatment-coded interpretation follows from the log link and linear predictor. If the modeled response or link is different, the coefficient interpretation may differ.

Define the modeled frequency rate as \(\lambda_i=\mu_i/e_i\). For the reference level, all indicators are zero, so \(\lambda_{\mathrm{ref}}=\exp(\beta_0)\). For level \(j\), the rate is \(\exp(\beta_0+\beta_j)\). Thus the multiplier relative to the reference is \(\exp(\beta_j)\), and the percentage change relative to the reference is \(100[\exp(\beta_j)-1]\%\). The coefficient itself is on the log scale; it is not a rate or a percentage change.

Key result: In a log-link model with treatment coding, the intercept is the log fitted rate for the reference level when other predictors are at their specified reference or zero values. Each categorical coefficient is the log of the fitted rate ratio between its level and the omitted level, with other model predictors held fixed. Exponentiating the intercept gives the reference rate; exponentiating a factor coefficient gives its multiplicative relativity to that reference.

Why Exponentiating Gives the Relativity

The result follows directly by comparing the modeled rates. With other predictors fixed at the same values, write their combined contribution as \(c\). The reference rate is \(\exp(c+\beta_0)\). For level \(j\), its indicator adds \(\beta_j\), giving \(\exp(c+\beta_0+\beta_j)\). Dividing the latter rate by the former cancels the terms common to both levels:

$$ \frac{\exp(c+\beta_0+\beta_j)}{\exp(c+\beta_0)} =\exp(\beta_j). $$

This derivation also explains the phrase “holding other predictors fixed.” The ratio is a model-based comparison at the same values of those predictors. It need not equal a ratio of unadjusted portfolio averages when the levels have different mixes of other risks.

Worked Example: Reading Coefficients for Four Vehicle Classes

A hypothetical insurer fits a Poisson claim-frequency model with a log link and a policy-year exposure offset. Vehicle class A is the reference. The fitted reference frequency is \(0.080\) claims per policy-year. The reported coefficients are \(\beta_B=\log(1.25)=0.223144\), \(\beta_C=\log(0.80)=-0.223144\), and \(\beta_D=\log(1.50)=0.405465\). Find the fitted frequency for each class and the expected claim count for 500 policy-years in class C. Assume the fitted rates apply unchanged across the stated exposures.

Method. Exponentiate each coefficient to obtain its rate multiplier relative to class A, then multiply by the reference rate. The coefficient values imply multipliers 1.25, 0.80, and 1.50.

For class A, the rate is the reference rate: \(0.080\) claims per policy-year.

For class B, the rate is \(0.080\times1.25=0.100\) claims per policy-year.

For class C, the rate is \(0.080\times0.80=0.064\) claims per policy-year.

For class D, the rate is \(0.080\times1.50=0.120\) claims per policy-year.

The expected count for class C is exposure times its fitted rate: \(500\times0.064=32\) claims. The fitted frequency is \(32/500=0.064\) claims per policy-year, which checks the calculation.

Common mistake avoided: The class C coefficient is \(-0.223144\), but that does not mean a negative frequency or a decrease of 0.223144 claims per policy-year. Its exponent is \(0.80\), so class C's modeled frequency is 20% lower than class A's, with other predictors held fixed.

Changing the Reference Changes the Coefficients

The reference level determines which fitted rate is represented by the intercept and which comparisons are represented by the other coefficients. To change references without changing the model's fitted rates, rewrite the same level-specific linear predictors using a new baseline. The new intercept becomes the old fitted linear predictor at the new reference; each new coefficient is the difference between its level's old linear predictor and the new reference's old linear predictor.

For the single-factor model above, if class \(r\) becomes the reference, the new intercept is \(\beta_0+\beta_r\) (where the old reference has \(\beta_r=0\)). For another level \(j\), its new coefficient is \(\beta_j-\beta_r\). These are changes in parameterization, not changes in the underlying fitted values.

Worked Example: Re-Expressing the Same Model With a New Reference

Use the class A–D hypothetical frequency model from the preceding calculation, but now choose class C as the reference. The original fitted rates are A: \(0.080\), B: \(0.100\), C: \(0.064\), and D: \(0.120\) claims per policy-year. Find the new intercept and the coefficients for A, B, and D. Verify that the new parameterization recovers the same rates.

Method. The new reference rate is class C's fitted rate, \(0.064\), so the new intercept is its natural logarithm: \(\log(0.064)=-2.748872\). This is the log rate for C, rather than the old log rate for A.

The new coefficient for A is \(\log(0.080/0.064)=\log(1.25)=0.223144\). The new coefficient for B is \(\log(0.100/0.064)=\log(1.5625)=0.446287\). The new coefficient for D is \(\log(0.120/0.064)=\log(1.875)=0.628609\). Each is the log of that level's rate relative to class C.

Check the rates by exponentiating the new linear predictors. For C, \(\exp(-2.748872)=0.064\). For A, \(\exp(-2.748872+0.223144)=\exp(\log 0.080)=0.080\). For B, \(\exp(-2.748872+0.446287)=\exp(\log 0.100)=0.100\). For D, \(\exp(-2.748872+0.628609)=\exp(\log 0.120)=0.120\), with displayed log values rounded to six decimals. The original fitted rates are recovered.

Common mistake avoided: Simply relabeling class C as the reference while retaining the old intercept and coefficients would produce incorrect predictions. The intercept and every coefficient must be re-expressed relative to the new baseline.

Interpretation With Other Rating Factors

A categorical coefficient is conditional on the other terms in the specified model. It is not automatically a comparison of observed averages across all policies in the levels. The following example includes a second rating factor to make the conditioning explicit. The fitted rates are model predictions, not claims that every risk in a level has identical actual experience.

Worked Example: Holding a Second Rating Factor Fixed

A hypothetical frequency model uses territory and vehicle use, with a log link and policy-year offset. Territory A is the reference, and private use is the reference for vehicle use. The fitted frequency for a territory-A private-use risk is \(0.060\) claims per policy-year. The territory coefficients are \(\beta_B=\log(1.30)=0.262364\) and \(\beta_C=\log(0.75)=-0.287682\). The commercial-use coefficient is \(\gamma=\log(1.40)=0.336472\). Find the fitted rate and expected count for a territory-B commercial-use risk with 25 policy-years, and for a territory-C private-use risk with 10 policy-years.

Method. The reference rate is \(0.060\). In this additive log-linear model, exponentiating the relevant coefficient adds its multiplicative factor to that rate. For territory B with commercial use, the rate is \(0.060\times1.30\times1.40=0.1092\) claims per policy-year. Its expected count is \(25\times0.1092=2.73\) claims.

For territory C with private use, only the territory-C factor applies: \(0.060\times0.75=0.045\) claims per policy-year. Its expected count is \(10\times0.045=0.45\) claims. Dividing the expected counts by their exposures returns \(2.73/25=0.1092\) and \(0.45/10=0.045\), respectively.

The territory-B coefficient compares territory B with A at the same vehicle-use category. It does not by itself compare the overall observed frequencies in all B and A policies if the proportions of commercial and private use differ. This interpretation also relies on the specified model having no territory-by-use interaction; with an interaction, the territory effect could vary by use.

Common mistake avoided: Applying only the territory-B factor and reporting \(0.060\times1.30=0.078\) as the commercial-use rate omits a model term. The requested risk has both territory B and commercial use, so both multipliers are required.

Common Interpretation Traps

  • Treating a log coefficient as a rate multiplier. If \(\beta=0.2231\), the multiplier is \(\exp(\beta)\), approximately 1.25, not 0.2231.
  • Calling the coefficient a percentage change without exponentiating. The exact percentage change for coefficient \(\beta\) is \(100[\exp(\beta)-1]\%\). A log coefficient of 0.2231 corresponds to approximately a 25% increase, not 22.31%.
  • Forgetting which level is omitted. A coefficient is relative to the stated reference. Without identifying that reference, the interpretation is incomplete.
  • Assuming the reference is an average level. Treatment coding makes the reference's indicators zero; it does not make the reference statistically average or representative.
  • Ignoring other model terms or interactions. A main-effect coefficient is interpreted with the other modeled predictors held fixed. If interactions are included, the effect associated with a factor may depend on the interacting factor's level.
  • Changing the reference but keeping the old numbers. A new reference requires a correspondingly re-expressed intercept and coefficients. Otherwise, the model predictions change.
Key takeaway: First identify the omitted level. In a log-link model, exponentiate a treatment-coded coefficient to obtain its multiplicative effect relative to that level, conditional on the other predictors. The intercept belongs to the reference configuration. A different reference gives different reported coefficients, but a correct reparameterization preserves every fitted rate.

Check Your Understanding

For each hypothetical model, interpret the coefficient using the stated reference and keep exposure units consistent.

  1. A log-link frequency model uses roof type, with slate as reference. The fitted slate rate is \(0.050\) claims per policy-year and the tile coefficient is \(\log(1.20)\). Find the tile rate and its percentage change relative to slate. (Answer: \(0.060\) claims per policy-year; 20% higher.)
  2. A three-level territory factor uses North as reference. Its fitted rate is \(0.040\), while South and West coefficients are \(\log(0.75)\) and \(\log(1.50)\). Find the West rate and expected count for 80 policy-years. (Answer: \(0.060\) claims per policy-year and 4.8 expected claims.)
  3. A factor has levels L, M, and H, with L as reference. The fitted rates are \(0.080\), \(0.100\), and \(0.060\), respectively. If H becomes the reference, give the new reference rate and the new coefficient for M. (Answer: reference rate \(0.060\); M coefficient \(\log(0.100/0.060)=\log(5/3)\approx0.510826\).)
  4. A model's reference rate is \(0.030\). A building-level coefficient is \(-0.223144\), and another included factor contributes a multiplier of 1.5 for the risk in question. Find the fitted rate when both terms apply. (Answer: \(0.030\times\exp(-0.223144)\times1.5=0.030\times0.8\times1.5=0.036\) claims per policy-year.)
  5. A model reports an indicator coefficient of \(\log(0.90)\) for a level relative to its reference, whose fitted rate is \(0.070\). A candidate adds \(0.90\) to \(0.070\). State the correct fitted rate and explain the error. (Answer: \(0.070\times0.90=0.063\) claims per policy-year; the coefficient's exponent is a multiplier, not an additive rate adjustment.)
Clinical Biostats