Tutorials › Exam SRM - Statistics for Risk Modeling › Prediction And Uncertainty For Gamma Responses

Exam SRM · Poisson and Gamma Models · Tutorial 343 of 926

Prediction And Uncertainty For Gamma Responses

Use a fitted Gamma model to calculate response variability and interpret predictive uncertainty without mistaking a conditional mean for an individual outcome.

Advanced 10 min read

What You'll Learn

  • Distinguish a conditional mean prediction from a future individual response.
  • Calculate Gamma response variance, standard deviation, and coefficient of variation.
  • Explain how the mean-variance relationship changes uncertainty across fitted means.
  • Use a Gamma distribution to calculate a response tail probability.
  • Separate response variability from uncertainty in estimated model parameters.

What a Gamma Prediction Does—and Does Not—Tell You

A fitted Gamma model predicts a positive response amount through its conditional mean. That mean is a summary for responses with the stated covariates; it is not a promise that the next individual response will equal the prediction. The model also describes how much individual outcomes can vary around that mean. Distinguishing these two ideas is important when communicating predicted costs, claim amounts, or other positive skewed outcomes. The treatment here is aligned with the SOA Exam SRM (Statistics for Risk Modeling) syllabus.

The earlier material on Gamma regression establishes the conditional mean and dispersion framework. This tutorial focuses on interpreting predictive uncertainty once those quantities have been fitted. Unless stated otherwise, calculations use a plug-in approach: the fitted mean and dispersion are treated as fixed, and uncertainty refers to variation in a future response conditional on the covariates.

Definition: For a Gamma response \(Y\) conditional on covariates \(x\), write its fitted conditional mean as \(\mu=E[Y\mid x]\) and its dispersion as \(\phi>0\). Under the Gamma mean-variance model, \(E[Y\mid x]=\mu\) and \(\operatorname{Var}(Y\mid x)=\phi\mu^2\). The conditional standard deviation is \(\sqrt{\phi}\mu\), and the conditional coefficient of variation is \(\sqrt{\phi}\).

In this parameterization, \(Y\mid x\) has a Gamma distribution with shape \(\alpha=1/\phi\) and scale \(\theta=\phi\mu\). Its support is positive. The shape is common when the model uses a common dispersion, while the scale changes with the fitted mean. The formulas require a positive mean and positive dispersion; they do not describe a response that can be zero or negative.

Why the Variance Depends on the Square of the Mean

The quadratic mean-variance relationship follows directly from the Gamma parameterization. For a Gamma random variable with shape \(\alpha\) and scale \(\theta\), the mean is \(\alpha\theta\) and the variance is \(\alpha\theta^2\). Substituting \(\alpha=1/\phi\) and \(\theta=\phi\mu\) gives:

$$ E[Y\mid x] =\alpha\theta =\frac{1}{\phi}(\phi\mu) =\mu, \qquad \operatorname{Var}(Y\mid x) =\alpha\theta^2 =\frac{1}{\phi}(\phi\mu)^2 =\phi\mu^2. $$

Taking the square root gives \(\operatorname{SD}(Y\mid x)=\sqrt{\phi}\mu\), since both \(\phi\) and \(\mu\) are positive. Dividing this standard deviation by the mean gives \(\operatorname{CV}(Y\mid x)=\sqrt{\phi}\). Thus, for fixed dispersion, doubling the fitted mean doubles the standard deviation and multiplies the variance by four. The relative variability, measured by the coefficient of variation, stays the same.

This is a model relationship, not a claim that all positive outcomes have the same relative variability. If dispersion differs across fitted models or is estimated differently, the coefficient of variation differs too. A fitted dispersion is also not itself a standard deviation: the standard deviation as a proportion of the mean is its square root.

Worked Example: Translating a Fitted Mean Into Individual-Response Uncertainty

A hypothetical model for a positive equipment repair cost has fitted conditional mean \(\$300\) and dispersion \(\phi=0.2\). Treat these fitted values as fixed. Find the Gamma shape and scale, conditional variance, standard deviation, and coefficient of variation. State what the fitted mean means for a future repair.

Method. Use the Gamma shape-scale parameterization and the conditional mean-variance formulas. The shape and scale are:

$$ \alpha=\frac{1}{\phi}=\frac{1}{0.2}=5, \qquad \theta=\phi\mu=0.2(300)=60\text{ dollars}. $$

The mean check is \(\alpha\theta=5(60)=300\) dollars, which agrees with the fitted conditional mean.

The variance is:

$$ \operatorname{Var}(Y\mid x) =\phi\mu^2 =0.2(300)^2 =0.2(90{,}000) =18{,}000\text{ dollars}^2. $$

The standard deviation is \(\sqrt{18{,}000}=134.164\ldots\) dollars, or \(\$134.16\) to the nearest cent. The coefficient of variation is \(\sqrt{0.2}=0.447213\ldots\), or \(0.4472\) to four decimal places. The fitted mean says the model’s average repair cost for this covariate profile is \(\$300\); it does not say that each repair will cost \(\$300\).

Check. The standard deviation divided by the mean is \(134.164\ldots/300=0.447213\ldots\), matching the coefficient of variation. A common mistake is to write the variance as \(\$18{,}000^2\), which means the square of 18,000 dollars. The calculated variance is instead 18,000 dollars squared: the number is 18,000, and its units are squared dollars.

How Uncertainty Changes Across Fitted Means

For two covariate profiles with the same dispersion, the profile with the larger fitted mean has a larger variance in absolute units. This does not mean it has greater relative variability: the coefficient of variation remains fixed. The distinction matters when comparing amounts on very different scales. Absolute standard deviations answer how far responses typically vary in the response’s units; coefficients of variation compare variability relative to each mean.

More generally, if two fitted means are \(\mu_1\) and \(\mu_2\), with the same \(\phi\), then their conditional variances are \(\phi\mu_1^2\) and \(\phi\mu_2^2\). Their variance ratio is the square of the mean ratio, and their standard-deviation ratio is the mean ratio. These comparisons require the same dispersion. If dispersions differ, calculate each variance using that profile’s own dispersion rather than attributing every difference to the mean.

Worked Example: Comparing Two Fitted Conditional Distributions

A hypothetical Gamma model for positive replacement costs has common dispersion \(\phi=0.16\). For two equipment profiles, the fitted means are \(\$200\) and \(\$500\). Calculate each conditional standard deviation and variance, then compare the absolute and relative uncertainty.

For the first profile, \(\mu_1=200\). Its variance and standard deviation are:

$$ \operatorname{Var}(Y_1\mid x_1) =0.16(200)^2 =0.16(40{,}000) =6{,}400\text{ dollars}^2, \qquad \operatorname{SD}(Y_1\mid x_1)=\sqrt{6{,}400}=80\text{ dollars}. $$

For the second profile, \(\mu_2=500\):

$$ \operatorname{Var}(Y_2\mid x_2) =0.16(500)^2 =0.16(250{,}000) =40{,}000\text{ dollars}^2, \qquad \operatorname{SD}(Y_2\mid x_2)=\sqrt{40{,}000}=200\text{ dollars}. $$

The mean ratio is \(500/200=2.5\). The standard-deviation ratio is \(200/80=2.5\), while the variance ratio is \(40{,}000/6{,}400=6.25=(2.5)^2\). Both profiles have coefficient of variation \(\sqrt{0.16}=0.4\). Therefore the second profile has greater uncertainty in dollars, but not greater relative uncertainty under this model.

Check. The standard deviations are 40% of their respective means: \(80/200=0.4\) and \(200/500=0.4\). A common mistake is to multiply the variance by 2.5 because the mean increases by that factor. The variance is proportional to the square of the mean, so it increases by \(2.5^2=6.25\).

Predictive Probabilities and Individual Outcomes

Moments summarize a conditional distribution, but a decision may depend on a threshold: for example, whether an individual amount exceeds a specified level. The Gamma distribution supplies that probability. In general, a fitted mean and dispersion determine a Gamma distribution, and a predictive probability is calculated from that distribution—not by treating the mean as the outcome.

When the shape \(\alpha\) is a positive integer, the Gamma tail probability has a convenient finite-sum expression. If \(Y\) has shape \(\alpha=n\) and scale \(\theta\), then for \(y>0\):

$$ P(Y>y) =e^{-y/\theta}\sum_{k=0}^{n-1}\frac{(y/\theta)^k}{k!}. $$

This expression follows by integrating the Gamma density from \(y\) to infinity; repeated integration by parts reduces the integral to the displayed sum when the shape is an integer. For non-integer shape, the same probability is obtained from the Gamma distribution function or its numerical evaluation, rather than this finite sum.

Worked Example: Comparing the Chance of Exceeding a Fixed Amount

Two hypothetical portfolios have Gamma-distributed positive individual costs with the same dispersion, \(\phi=0.2\). The fitted means are \(\$100\) and \(\$200\). For each portfolio, calculate the probability that an individual cost exceeds \(\$200\). Give probabilities to four decimal places.

Here \(\alpha=1/\phi=5\) for both distributions. For the first portfolio, \(\mu_1=100\), so \(\theta_1=\phi\mu_1=20\) dollars. At threshold \(y=200\), \(y/\theta_1=10\), and:

$$ P(Y_1>200) =e^{-10}\left(1+10+\frac{10^2}{2!} +\frac{10^3}{3!}+\frac{10^4}{4!}\right) =e^{-10}(644.3333\ldots) =0.0293. $$

For the second portfolio, \(\mu_2=200\), so \(\theta_2=0.2(200)=40\) dollars. Now \(y/\theta_2=200/40=5\), and:

$$ P(Y_2>200) =e^{-5}\left(1+5+\frac{5^2}{2!} +\frac{5^3}{3!}+\frac{5^4}{4!}\right) =e^{-5}(65.375) =0.4405. $$

Thus the fitted mean of the second portfolio equals the threshold, and its probability of exceeding that threshold is \(0.4405\), not 1. The first portfolio has a smaller mean and a much smaller probability of exceeding \(\$200\), \(0.0293\). The probabilities are computed from each full conditional distribution. They are not determined by comparing the threshold with the mean alone.

Check. The scale values are \(\$20\) and \(\$40\), and both shapes equal 5. Substituting the threshold-to-scale ratios 10 and 5 into the integer-shape tail formula gives the stated probabilities. A common mistake is to assume that an amount equal to the mean is exceeded with probability one-half. A Gamma distribution is generally skewed, so that conclusion does not follow.

Response Variability Is Not Parameter Uncertainty

The variance \(\phi\mu^2\) describes the spread of individual responses conditional on the covariates and on the model parameters. In practice, \(\mu\) and \(\phi\) are estimated from data. Their estimation introduces a separate source of uncertainty. A plug-in prediction substitutes the fitted values into the Gamma distribution; it captures modeled response variability but does not, by itself, fully account for uncertainty in the fitted regression coefficients or dispersion.

This distinction affects the interpretation of intervals. A predictive interval for a future individual response should reflect the response distribution and, when the method calls for it, uncertainty in the estimated parameters. An interval for the conditional mean instead concerns uncertainty about that mean. These intervals answer different questions: one concerns an individual future outcome, and the other concerns the estimated average at specified covariates. Do not label a confidence interval for the mean as an individual prediction interval.

1
Identify the target.
Decide whether the question asks for a conditional mean, an individual response variance, a tail probability, or uncertainty in an estimated mean.
2
Record the fitted quantities.
For a response prediction, identify the fitted conditional mean \(\hat{\mu}\) and the dispersion estimate \(\hat{\phi}\), using the model’s stated assumptions.
3
Calculate and interpret.
For plug-in response variability, use \(\hat{\phi}\hat{\mu}^2\) for variance and \(\sqrt{\hat{\phi}}\hat{\mu}\) for standard deviation. Use the Gamma distribution itself for a requested probability or quantile.

Common Traps

  • Calling the fitted mean an individual prediction. The mean is the conditional average; individual responses vary according to the fitted response distribution.
  • Forgetting to square the mean in the variance. Gamma variance is \(\phi\mu^2\), not \(\phi\mu\). Doubling the mean at fixed dispersion quadruples the variance.
  • Reporting variance in response units. If the response is measured in dollars, variance is measured in dollars squared; standard deviation is measured in dollars.
  • Confusing dispersion with coefficient of variation. With this Gamma parameterization, the coefficient of variation is \(\sqrt{\phi}\), not \(\phi\).
  • Ignoring the question’s target. Response variability, uncertainty in a fitted mean, and uncertainty in a future response are not interchangeable.
Key takeaway: For a Gamma response with conditional mean \(\mu>0\) and dispersion \(\phi>0\), individual-response variance is \(\phi\mu^2\), standard deviation is \(\sqrt{\phi}\mu\), and coefficient of variation is \(\sqrt{\phi}\). These describe a conditional response distribution; they do not turn the fitted mean into a guaranteed individual outcome.

Check Your Understanding

For each problem, treat the stated Gamma mean and dispersion as fixed unless the question says otherwise. Round probabilities to four decimal places.

  1. A hypothetical model predicts a positive inspection cost with mean \(\$250\) and dispersion \(0.12\). Find the conditional variance, standard deviation, and coefficient of variation. (Answer: variance \(=7{,}500\text{ dollars}^2\); standard deviation \(=\$86.60\); coefficient of variation \(=0.3464\).)
  2. A fitted Gamma response has mean \(\$400\) and dispersion \(0.25\). Find its shape, scale, variance, and standard deviation. (Answer: shape \(=4\); scale \(=\$100\); variance \(=40{,}000\text{ dollars}^2\); standard deviation \(=\$200\).)
  3. Two profiles have fitted means \(\$150\) and \(\$300\), each with dispersion \(0.09\). Compare their variances and standard deviations, and state whether their coefficients of variation differ. (Answer: variances \(=2{,}025\) and \(8{,}100\text{ dollars}^2\); standard deviations \(=\$45\) and \(\$90\); both coefficients of variation are \(0.3\).)
  4. A Gamma response has mean \(\$240\) and dispersion \(0.25\). Its shape is an integer. Calculate the probability that it exceeds its mean. (Answer: \(P(Y>240)=e^{-4}(1+4+8+64/6)=0.4335\).)
  5. A hypothetical Gamma model gives a response mean of \(\$180\) and dispersion \(0.16\). State the plug-in conditional standard deviation and explain whether it includes uncertainty in the estimated regression coefficients. (Answer: standard deviation \(=\sqrt{0.16}(180)=\$72\); it describes conditional response variability and does not by itself include coefficient-estimation uncertainty.)
Clinical Biostats