Tutorials › Generalized Linear Models › Family Choice and Predictive Uncertainty

Choosing Continuous Families · Tutorial 649 of 981

Family Choice and Predictive Uncertainty

Learn how different response families translate the same fitted mean into different predictive intervals, tails, and probabilities of zero.

Intermediate 11 min read

What You'll Learn

  • Distinguish predictive distributions from uncertainty about a fitted mean.
  • Compare the supports and variance functions of four continuous-response families.
  • Derive and interpret family-specific skewness at a fixed mean and variance.
  • Calculate predictive intervals for Gaussian and gamma models with the same mean and variance.
  • Work out the zero probability of a compound Poisson–gamma Tweedie model.
  • Recognize when a family implies implausible future responses or hides important zero probability.

Why the Family Changes a Prediction

Two fitted models can give the same response mean for a patient with specified covariates and still tell quite different stories about that patient’s next outcome. One model may allow negative values; another may place all its probability on positive values; a third may assign positive probability to an exact zero. Even when two models have the same mean and variance, their predictive intervals can differ in width and asymmetry because their distributions have different shapes.

Here, a predictive distribution means the model’s conditional distribution for a future response \(Y\), given its covariates and the fitted parameters. Unless noted otherwise, the comparisons below hold those parameters fixed. They describe response variation under the fitted model, not uncertainty about an estimated mean or about the parameters themselves.

Definition: A central \(100(1-2\alpha)\%\) predictive interval for a future response is \([Q_{\alpha},Q_{1-\alpha}]\), where \(Q_u=\inf\{y:F_Y(y)\geq u\}\) is the \(u\)-quantile of its conditional predictive distribution. For a continuous distribution, the interval contains probability \(1-2\alpha\); if the distribution has an atom, the quantile definition also applies, though the interval’s actual probability can exceed that nominal level.

The distinction matters in applications. A negative lower endpoint may be a warning for a nonnegative outcome, while an interval that starts at zero can reflect a genuine point mass there rather than a small positive value. Neither feature is visible from the fitted mean alone.

Four Families, Four Predictive Shapes

Write \(\mu>0\) for the conditional mean at the covariate pattern of interest and \(\phi>0\) for the dispersion. For the positive-response families below, the variance functions are conventionally written as follows. The Tweedie row refers to the compound Poisson–gamma case \(1<p<2\).

FamilyConditional varianceSupport and shape implication
Gaussian\(\phi\)All real values; symmetric about the mean
Gamma\(\phi\mu^2\)Positive values; right-skewed
Inverse Gaussian\(\phi\mu^3\)Positive values; typically strongly right-skewed
Tweedie, \(1<p<2\)\(\phi\mu^p\)Nonnegative values; a point mass at zero and a continuous positive part

At a given covariate pattern, the family and dispersion together determine the response variation. If two families are fitted to the same data, their dispersions need not match, and neither do their predictive variances. Even a deliberate comparison with the same mean and variance does not make the predictive distributions equivalent: the Gaussian remains symmetric, whereas the positive families have longer right tails, and the compound Poisson–gamma Tweedie distribution can put probability at zero.

Skewness When Mean and Variance Are Held Fixed

A useful way to make the shape difference precise is the conditional skewness, \(E[(Y-\mu)^3]/\operatorname{Var}(Y)^{3/2}\). For the standard regular exponential-dispersion parameterization, the conditional cumulant generating function is \(K_Y(t)=[b(\theta+\phi t)-b(\theta)]/\phi\), in a neighborhood of zero where it exists. The mean is \(b'(\theta)=\mu\), and the variance function is \(V(\mu)=b''(\theta)\).

Result: For a regular exponential-dispersion model with the third moment finite, \(\kappa_3(Y)=\phi^2 V(\mu)V'(\mu)\), where \(\kappa_3(Y)=E[(Y-\mu)^3]\). Consequently, the skewness is \(\sqrt{\phi}\,V'(\mu)/\sqrt{V(\mu)}\).

To derive the result, differentiate the cumulant generating function at zero. Its second derivative is \(\phi b''(\theta)=\phi V(\mu)\); its third derivative is \(\phi^2 b'''(\theta)\). By the chain rule, \(b'''(\theta)=\frac{d}{d\theta}V(\mu)=V'(\mu)\frac{d\mu}{d\theta}=V'(\mu)V(\mu)\), because \(d\mu/d\theta=b''(\theta)=V(\mu)\). The third cumulant is the third central moment when it exists. Dividing it by the variance to the power \(3/2\) gives \(\phi^2 V V'/(\phi V)^{3/2}=\sqrt{\phi}\,V'/\sqrt V\). \(\square\)

Applying this calculation to the variance functions gives Gaussian skewness \(0\), gamma skewness \(2\sqrt{\phi}\), inverse-Gaussian skewness \(3\sqrt{\phi\mu}\), and Tweedie skewness \(p\sqrt{\phi}\mu^{p/2-1}\). These formulas describe conditional distributions under the stated parameterizations. In particular, the expressions need not be equal just because two models have been arranged to share a mean and variance.

Worked Example: Equal Mean and Variance, Unequal Intervals

Compare a Gaussian and a gamma predictive distribution with mean \(2\) and variance \(4\). Calculate their central 90% predictive intervals.

Gaussian. The variance is \(4\), so the standard deviation is \(2\). The central 90% normal interval is \(2\pm z_{0.95}(2)\), with \(z_{0.95}\approx1.644854\). Its endpoints are \(2-3.289708=-1.289708\) and \(2+3.289708=5.289708\), giving width \(6.579416\).

Gamma. For a gamma distribution with shape \(k\) and scale \(s\), the mean is \(ks\) and the variance is \(ks^2\). Solving \(ks=2\) and \(ks^2=4\) gives \(s=4/2=2\) and \(k=2/2=1\). This is an exponential distribution with mean \(2\), whose cumulative distribution function is \(F(y)=1-e^{-y/2}\) for \(y\geq0\). Its quantile is \(Q_u=-2\log(1-u)\). Thus \(Q_{0.05}=-2\log(0.95)\approx0.1026\) and \(Q_{0.95}=-2\log(0.05)\approx5.9915\). The interval width is approximately \(5.8889\).

Both distributions have mean \(2\) and variance \(4\), yet the Gaussian interval is wider in this comparison and extends below zero. The gamma interval is asymmetric about the mean: its distances from \(2\) to the lower and upper endpoints are approximately \(1.8974\) and \(3.9915\). The difference follows from distributional shape, not from a difference in the two stated moments.

Inverse-Gaussian Predictions: Positive and Often More Skewed

The inverse-Gaussian family is another positive-response option, with a variance that grows as the cube of the mean. Under the standard parameterization with mean \(\mu\) and shape parameter \(\lambda\), its variance is \(\mu^3/\lambda\), so \(\phi=1/\lambda\). Its density is \(f(y)=\sqrt{\lambda/(2\pi y^3)}\exp\{-\lambda(y-\mu)^2/(2\mu^2y)\}\) for \(y>0\).

Worked Example: Matching an Inverse-Gaussian Variance

Suppose the conditional mean is \(2\) and the desired conditional variance is \(4\). For an inverse-Gaussian model, \(\phi=\operatorname{Var}(Y)/\mu^3=4/2^3=1/2\), so \(\lambda=1/\phi=2\). The skewness is \(3\sqrt{\phi\mu}=3\sqrt{(1/2)(2)}=3\).

For comparison, the gamma model in the preceding example has skewness \(2\sqrt{\phi}=2\sqrt{1}=2\), and the Gaussian model has skewness zero. These three models share the same mean and variance, but their skewnesses differ. The inverse-Gaussian model’s support is positive, and its larger skewness indicates a more pronounced right-skewed shape. The calculation identifies a shape difference; it does not, by itself, determine the precise endpoints of a particular predictive interval.

A predictive interval from a positive continuous family cannot include negative outcomes, but its upper endpoint can be sensitive to the right tail. A symmetric Gaussian interval, by contrast, allocates equal distances from the mean to its endpoints. These differences can affect how a model represents unusually large costs, durations, or other positive outcomes.

Tweedie Predictions and the Probability of Zero

For \(1<p<2\), the Tweedie distribution has a compound Poisson–gamma representation. Let \(N\) be Poisson with mean \(\lambda\), let the positive jumps \(J_1,J_2,\ldots\) be independent gamma variables with shape \(a\) and scale \(s\), independent of \(N\), and set \(Y=\sum_{j=1}^{N}J_j\), taking the empty sum to be zero. For conditional mean \(\mu\) and dispersion \(\phi\), the parameters are \(\lambda=\mu^{2-p}/[\phi(2-p)]\), \(a=(2-p)/(p-1)\), and \(s=\phi(p-1)\mu^{p-1}\).

Result: Under this representation, \(P(Y=0)=e^{-\lambda}\), \(E[Y]=\mu\), and \(\operatorname{Var}(Y)=\phi\mu^p\).

Because gamma jumps are strictly positive, \(Y=0\) exactly when \(N=0\), so \(P(Y=0)=P(N=0)=e^{-\lambda}\). For a gamma jump, \(E[J]=as\) and \(E[J^2]=a(a+1)s^2\). Conditioning on \(N\), or summing the means and variances of the independent jumps, gives \(E[Y]=\lambda as\) and \(\operatorname{Var}(Y)=\lambda E[J^2]\). Substituting the parameters, \(\lambda as=\mu\), and \(\lambda a(a+1)s^2=\phi\mu^p\). For the variance identity, use \(a(a+1)=(2-p)/(p-1)^2\); the factors \(2-p\) and \((p-1)^2\) cancel with those in \(\lambda\) and \(s^2\). This proves the stated mass and moments. \(\square\)

The point mass changes the interpretation of predictive quantiles. With the definition above, if \(P(Y=0)\geq\alpha\), then \(Q_\alpha=0\): the cumulative distribution has already reached probability \(\alpha\) at zero. A Gaussian, gamma, or inverse-Gaussian distribution has probability zero at any single point because it is continuous, although the Gaussian additionally permits negative responses and the gamma and inverse Gaussian do not.

Worked Example: A Tweedie Model With a Noticeable Zero Probability

Take \(p=1.5\), \(\mu=0.25\), and \(\phi=0.5\). The compound Poisson rate is \(\lambda=0.25^{\,0.5}/[0.5(0.5)]=0.5/0.25=2\). The gamma jump shape is \(a=0.5/0.5=1\), and its scale is \(s=0.5(0.5)(0.25^{\,0.5})=0.125\).

The probability of an exact zero is \(e^{-2}\approx0.1353\). The mean checks as \(\lambda as=2(1)(0.125)=0.25\). The variance checks as \(\lambda a(a+1)s^2=2(1)(2)(0.125^2)=0.0625\), which also equals \(\phi\mu^p=0.5(0.25^{1.5})=0.5(0.125)=0.0625\).

Since \(F(0)=0.1353>0.05\), the Tweedie fifth percentile is zero, and its central 90% predictive interval has lower endpoint zero. For a Gaussian distribution with the same mean and variance, the standard deviation is \(0.25\), giving a fifth percentile of \(0.25-1.644854(0.25)\approx-0.1612\). For a gamma distribution with that mean and variance, \(k=\mu^2/\operatorname{Var}(Y)=1\) and \(s=\operatorname{Var}(Y)/\mu=0.25\); its fifth percentile is \(-0.25\log(0.95)\approx0.0128\). All three distributions share the stated mean and variance, but their lower predictive outcomes differ: negative under the Gaussian, small but positive under the gamma, and exactly zero with probability about 13.5% under the Tweedie model.

Reading Predictive Intervals Responsibly

Predictive distributions make family choice consequential for the range of outcomes a fitted model treats as plausible. A Gaussian model can assign probability to values outside the physically possible range of a response. Gamma and inverse-Gaussian models avoid negative values, but their right-skewed tails can put substantial probability well above the mean. A Tweedie model with \(1<p<2\) additionally represents exact zeros through its point mass. Interval endpoints summarize some of these differences, but a full predictive distribution also conveys probabilities of particular events, such as \(P(Y>c)\) or \(P(Y=0)\).

These are conditional, model-based predictions. If fitted parameters are uncertain, a prediction that accounts for that uncertainty can differ from the distribution calculated by plugging in fixed estimates. Thus, a narrow interval under fixed fitted parameters should not automatically be read as total uncertainty about a future response.

Common mistake: “The fitted means and variances match, so the models must give essentially the same prediction interval.” Matching two moments does not determine a distribution. As the examples show, family-specific support, skewness, and—in the Tweedie case—a point mass can change plausible lower outcomes and interval endpoints. The correction is to inspect the predictive distribution relevant to the outcome, not just its mean and variance.

Check Your Understanding

Use the distributional properties and calculations in this tutorial to answer these questions.

  1. Why can two families with the same conditional mean and variance still have different central predictive intervals?
  2. A Gaussian model for a positive outcome gives a negative lower predictive endpoint. What feature of its support explains this, and what does it suggest you should check?
  3. For a Tweedie model with \(1<p<2\), what event must occur for the response to equal zero, and how does that give its zero probability?
  4. With \(\mu=1\), \(\phi=0.5\), and \(p=1.5\), calculate the Tweedie Poisson rate and the probability of an exact zero.
  5. How does uncertainty about fitted parameters differ from the conditional response variation represented by a predictive distribution with parameters held fixed?
Clinical Biostats