Why Separate Mean Effects From Dispersion?
A Gamma regression describes positive continuous outcomes whose variability tends to increase with their mean. For example, a hypothetical insurer might model positive repair costs using policy characteristics. The regression coefficients describe how the modeled mean changes with those characteristics. The dispersion parameter describes the amount of variation around that mean. Treating these as separate quantities is essential: dispersion is not another coefficient that changes the mean.
The earlier material on Gamma parameterizations and the Gamma mean-variance relationship uses the mean-dispersion form. We use that form here to write the likelihood and see what maximum likelihood estimates. Assume observations \(Y_1,\ldots,Y_n\) are independent, strictly positive, and have means \(\mu_i>0\). Assume a common dispersion \(\phi>0\), with \(\operatorname{Var}(Y_i)=\phi\mu_i^2\). The mean model is \(g(\mu_i)=\eta_i=\mathbf{x}_i^\mathsf{T}\boldsymbol{\beta}\), where \(g\) is a specified link and \(\mathbf{x}_i\) is the covariate vector, including an intercept if appropriate.
This density requires positive responses and a positive mean. It is not a model for exact zeros or negative outcomes. The common-\(\phi\) assumption also matters: if the observations have different dispersions, the likelihood and score equations must reflect that structure rather than silently treating them as equal.
The Likelihood and What It Estimates
Independence makes the joint likelihood the product of the individual densities. Taking logarithms gives a sum, which is easier to differentiate. Write \(k=1/\phi\), the Gamma shape parameter. The log likelihood is
The terms involving the mean model are \(-k\sum_i(\log\mu_i+y_i/\mu_i)\). Since \(k>0\), maximizing the likelihood over \(\boldsymbol{\beta}\), for any fixed common \(\phi\), is equivalent to minimizing \(\sum_i(\log\mu_i+y_i/\mu_i)\). The factor \(k\) changes the scale of this objective, not the location of its maximizer. Thus, when the mean model and common-dispersion assumptions hold and there are no additional constraints or penalties, changing \(\phi\) does not change the maximum-likelihood estimate of \(\boldsymbol{\beta}\). It does change the likelihood curvature and the estimated variability of the responses.
Coefficient Score: Why the Dispersion Factor Cancels
The score equation shows the same separation locally. First differentiate the log density with respect to \(\mu_i\):
By the chain rule, with \(\eta_i=\mathbf{x}_i^\mathsf{T}\boldsymbol{\beta}\), the coefficient score is
Every term has the same positive factor \(1/\phi\). Setting the score equal to zero therefore gives coefficient estimating equations that do not depend on the value of the common \(\phi\). The link still matters through \(d\mu_i/d\eta_i\); this cancellation does not mean that different links give the same coefficient estimates.
For the log link, \(\eta_i=\log\mu_i\), so \(d\mu_i/d\eta_i=\mu_i\). The score becomes \(\sum_i\mathbf{x}_i(y_i-\mu_i)/(\phi\mu_i)=\mathbf{0}\), or, after removing \(1/\phi\), \(\sum_i\mathbf{x}_i(y_i/\mu_i-1)=\mathbf{0}\). This gives a particularly direct illustration of the separation.
Worked Example: Estimate Log-Link Effects From Two Groups
A hypothetical study records positive claim amounts, in dollars, for two policy groups. Group A has observations \(80\) and \(120\); Group B has observations \(120\) and \(180\). Fit a saturated log-link model with \(x=0\) for Group A and \(x=1\) for Group B: \(\log\mu_i=\beta_0+\beta_1x_i\). Find the coefficient estimates and explain what they represent.
Method. Each group has its own fitted mean in this saturated model. For a group with observations \(y_1,y_2\), its contribution to the mean-dependent objective is \(2\log\mu+(y_1+y_2)/\mu\). Differentiating with respect to \(\mu\) gives \(2/\mu-(y_1+y_2)/\mu^2=0\), so the maximizing mean is the group arithmetic mean.
For Group A, \(\widehat\mu_A=(80+120)/2=100\). For Group B, \(\widehat\mu_B=(120+180)/2=150\). Since \(\log\widehat\mu_A=\widehat\beta_0\), \(\widehat\beta_0=\log(100)\). Since \(\log\widehat\mu_B=\widehat\beta_0+\widehat\beta_1\), \(\widehat\beta_1=\log(150)-\log(100)=\log(1.5)\approx0.4055\).
The estimated Group B mean is \(e^{\widehat\beta_1}=1.5\) times the Group A mean. These coefficients describe the fitted means; they are not estimates of dispersion. A common \(\phi\) affects the likelihood scale but not these coefficient estimates. Common mistake avoided: interpreting \(\widehat\beta_1=0.4055\) as a 40.55% increase. Under a log link the multiplicative change is \(e^{0.4055}=1.5\), a 50% increase.
Estimating the Dispersion by Maximum Likelihood
Unlike the coefficient score, the dispersion score involves the Gamma function. Differentiating with respect to the shape \(k=1/\phi\) gives
where \(\psi(k)=\frac{d}{dk}\log\Gamma(k)\) is the digamma function. The maximum-likelihood estimate of dispersion solves this score equation with the fitted means substituted. In general, there is no simple closed-form solution; a numerical root-finding method is used. This estimation presumes a common dispersion and correctly specified positive Gamma responses.
The equation also makes an important limitation clear: dispersion is estimated from how observations compare with their fitted means, not from the regression coefficients alone. Even if the mean model is unchanged, different observed residual patterns can lead to a different dispersion estimate.
Worked Example: Solve the Gamma Dispersion Score
Suppose three independent positive observations are \(1,2,3\), and the model has an intercept only. Estimate its mean and then find the maximum-likelihood dispersion numerically. For this calculation, take the fitted mean as the intercept-only maximum-likelihood estimate.
Step 1: Fit the mean. For an intercept-only Gamma model, the score equation reduces to \(\sum_i(y_i/\mu-1)=0\), so \(\widehat\mu=(1+2+3)/3=2\). The observed-to-fitted ratios are \(r_i=y_i/\widehat\mu=(0.5,1,1.5)\).
Step 2: Form the dispersion equation. With \(k=1/\phi\), set the score to zero and divide by \(n=3\):
The average ratio is \(1\). The average log ratio is \(\log(0.75)/3\approx-0.095894\). The equation therefore reduces to \(\log k-\psi(k)=0.095894\). Numerically solving gives \(\widehat k\approx5.375\), so \(\widehat\phi=1/\widehat k\approx0.1860\). As a check, \(\log(5.375)-\psi(5.375)\) is approximately \(0.0959\), matching the required value.
Step 3: Contrast with a Pearson estimate. The Pearson sum is \(\sum_i (y_i-\widehat\mu)^2/\widehat\mu^2=(1+0+1)/4=0.5\). With \(n=3\) observations and \(p=1\) fitted mean coefficient, the common Pearson-based estimate is \(0.5/(3-1)=0.25\). It differs from the likelihood estimate \(0.1860\); they are distinct estimation procedures, not interchangeable formulas for the same calculation. Common mistake avoided: setting dispersion equal to the Pearson estimate while claiming to have maximized the Gamma likelihood.
Dispersion Is Not a Mean Effect
The variance relationship gives a direct interpretation once the mean and dispersion are estimated. At mean \(\mu_i\), the response variance is \(\phi\mu_i^2\), and its standard deviation is \(\sqrt{\phi}\mu_i\). Thus, \(\phi\) controls relative variability: the coefficient of variation, standard deviation divided by mean, is \(\sqrt{\phi}\). It does not add to the linear predictor or directly multiply the mean.
Worked Example: Interpret a Fitted Dispersion Separately
Use the two-group log-link fit from the earlier worked example, and suppose a likelihood fit gives common dispersion \(\widehat\phi=0.16\). Calculate the fitted variance and standard deviation for each group, and distinguish these quantities from the group effect.
The fitted means are \(100\) for Group A and \(150\) for Group B. For Group A, \(\widehat{\operatorname{Var}}(Y\mid x=0)=0.16(100)^2=1{,}600\), giving standard deviation \(\sqrt{1{,}600}=40\). For Group B, \(\widehat{\operatorname{Var}}(Y\mid x=1)=0.16(150)^2=3{,}600\), giving standard deviation \(\sqrt{3{,}600}=60\).
Both groups have the same coefficient of variation, \(\sqrt{0.16}=0.4\). The coefficient \(\widehat\beta_1=\log(1.5)\) gives the 1.5 ratio between their fitted means; the dispersion \(0.16\) sets the relative variance around each mean. Equivalently, the Gamma shape is \(1/0.16=6.25\) in both groups, while the scales are \(0.16(100)=16\) and \(0.16(150)=24\). Common mistake avoided: reporting \(0.16\) as the variance. Variance depends on the mean and equals \(\phi\mu^2\), not \(\phi\) alone.
Practical Checks and Exam Traps
A reliable solution keeps the mean model and dispersion calculation distinct, while checking that both use the same fitted means and the same parameterization. In particular:
- Check the parameterization. Here shape is \(1/\phi\), scale is \(\phi\mu_i\), and variance is \(\phi\mu_i^2\). Other Gamma conventions may use a scale or rate directly; substituting those parameters without conversion changes the formulas.
- Keep the response positive. The continuous Gamma density above is defined for \(y_i>0\). It does not assign probability to an exact zero.
- Do not call every residual-based estimate an MLE. A Pearson estimate such as \(\sum_i (y_i-\widehat\mu_i)^2/\widehat\mu_i^2\) divided by residual degrees of freedom is a useful alternative estimate, but it is not generally the root of the Gamma likelihood score.
- Do not insert dispersion into the mean predictor. With a log link, \(\log\mu_i=\mathbf{x}_i^\mathsf{T}\boldsymbol{\beta}\). The dispersion controls the variance relationship; it is not an extra covariate coefficient.
- Check whether dispersion is common. The cancellation in the coefficient score relies on the common positive factor \(1/\phi\). Observation-specific dispersions require a different likelihood and need not give the same score equations.
These distinctions are aligned with the SOA Exam SRM (Statistics for Risk Modeling) syllabus: a candidate should be able to state the assumed Gamma model, identify which parameter governs the mean, and use the correct likelihood equation for dispersion rather than confusing it with a coefficient or a variance.
Check Your Understanding
For each problem, use the stated mean-dispersion parameterization and distinguish mean effects from dispersion.
- A Gamma response has mean \(80\) and dispersion \(0.25\). Find its shape, scale, and variance. (Answer: shape \(4\), scale \(20\), variance \(1{,}600\).)
- A saturated log-link model has group means estimated from observations \(90,150\) in Group A and \(120,200\) in Group B. Find the fitted means and the binary group coefficient. (Answer: means \(120\) and \(160\); coefficient \(\log(160/120)=\log(4/3)\approx0.2877\).)
- An intercept-only Gamma model is fitted to \(2,4,6\). Give the mean estimate and the numerical maximum-likelihood dispersion, using the same likelihood score procedure as in the worked example. (Answer: mean \(4\); dispersion approximately \(0.1860\).)
- For three fitted means \(50,100,200\), the observed responses are \(40,120,160\). With \(p=2\) mean coefficients, calculate the Pearson-based dispersion estimate using the denominator \(n-p\). (Answer: \(0.12\).)
- Under a log-link model, changing a binary covariate from \(0\) to \(1\) adds \(0.2\) to the linear predictor. If the common dispersion is \(0.10\), what is the mean multiplier, and by what factor does the variance change between these two covariate values? (Answer: mean multiplier \(e^{0.2}\approx1.2214\); variance multiplier \(e^{0.4}\approx1.4918\), with dispersion unchanged.)