Why the Choice of Link Matters
A generalized linear model separates the response distribution from the rule that connects its mean to predictors. The link specifies that connection. A canonical link has a particular relationship to the response distribution: it makes the linear predictor equal to the distribution’s natural parameter. This is more than a naming convention. It affects the likelihood equations and can make the score equations simpler.
A link does not have to be canonical to be used in a GLM. For example, the log link is a valid way to model a positive Gamma mean, even though the Gamma canonical link is an inverse link. The distinction is between a link’s mathematical connection to the response distribution and whether it is a suitable choice for the modeling objective.
In a GLM, observations are commonly assumed independent conditional on their predictors, with \(\eta_i=x_i^\mathsf{T}\beta\) and \(\mu_i=g^{-1}(\eta_i)\). The response distribution determines the mean-variance relationship. In the exponential-family representation above, \(\operatorname{Var}(Y_i)=a(\phi)b''(\theta_i)\). A link changes how the mean depends on the predictors; it does not, by itself, change the assumed response distribution.
Canonical and Noncanonical Choices
For a Poisson response with mean \(\mu>0\), the probability function can be written as \(\exp\{y\log\mu-\mu-\log(y!)\}\). Here \(\theta=\log\mu\) and \(b(\theta)=e^\theta\), so the canonical link is \(g(\mu)=\log\mu\). Equivalently, a Poisson GLM with a log link has \(\eta=\log\mu\).
For a Gamma response with mean \(\mu>0\) and dispersion \(\phi>0\), use the parameterization with variance \(\phi\mu^2\). Its natural parameter is \(\theta=-1/\mu\), and \(b(\theta)=-\log(-\theta)\). Under the definition above, the canonical link is therefore \(g(\mu)=-1/\mu\). This is often called the Gamma inverse link; some presentations use the positive inverse \(1/\mu\), absorbing the minus sign by reversing the sign of the predictor coefficients. The log link \(g(\mu)=\log\mu\) is also usable for Gamma means, but it is not canonical under this natural-parameter convention.
| Response model | Mean-variance relationship | Canonical link | Example of a noncanonical link |
|---|---|---|---|
| Poisson | \(\operatorname{Var}(Y)=\mu\) | \(\log\mu\) | Identity, if fitted means remain positive |
| Gamma | \(\operatorname{Var}(Y)=\phi\mu^2\) | \(-1/\mu\), or inverse with a sign convention | \(\log\mu\) |
A link must still be usable for the target mean: the inverse link must return a value in the response distribution’s mean domain. For instance, a Poisson mean must be positive, and a Gamma mean must be positive. A noncanonical link can be valid when this condition holds and the model is otherwise appropriately specified. Canonical does not mean universally preferable, and noncanonical does not mean incorrect.
Worked Example: Identifying a Poisson Canonical Link
A hypothetical insurer models the claim count for a policy using a Poisson response and a log link. For a particular policy, the fitted linear predictor is \(\eta=0.4\). Find the fitted mean count, state the natural parameter, and calculate the fitted variance. Name the method and a mistake it avoids.
Method: identify the natural parameter, then invert the link. For a Poisson response, \(\theta=\log\mu\), so the log link is canonical. Since \(\eta=g(\mu)=\log\mu\), $$ \mu=e^\eta=e^{0.4}=1.4918. $$ The natural parameter is \(\theta=\eta=0.4\). The Poisson variance equals its mean, so $$ \operatorname{Var}(Y)=\mu=1.4918. $$ Thus the fitted mean and variance are both approximately \(1.4918\) claims. The mean is an expected count and need not be an integer.
Check. Taking the logarithm of the fitted mean gives \(\log(1.4918)\approx0.4\), recovering the stated predictor.
Common mistake avoided: treating the predictor itself as the mean would give \(0.4\). The predictor is the log of the mean under this link; the mean is \(e^{0.4}\).
Worked Example: Gamma Inverse Versus Gamma Log
For a hypothetical severity model, the response is Gamma with dispersion \(\phi=0.16\). A model uses the signed canonical link \(g(\mu)=-1/\mu\), and a policy has predictor \(\eta=-0.5\). Find the fitted mean and variance. Then find the mean and variance if the same numerical predictor were used with a Gamma log link. Explain why the two models differ.
Method: invert each link separately. Under the signed canonical link, $$ -0.5=-\frac{1}{\mu} \quad\Longrightarrow\quad \mu=2. $$ The Gamma variance is \(\phi\mu^2\), giving $$ \operatorname{Var}(Y)=0.16(2^2)=0.64. $$ For the Gamma log link, \(\eta=\log\mu\), so the fitted mean is instead $$ \mu=e^{-0.5}=0.6065. $$ Its fitted variance is $$ \operatorname{Var}(Y)=0.16(0.6065^2)\approx0.0589. $$ The same predictor does not imply the same mean because the two links map predictors to means differently. Both means are positive, so both satisfy the Gamma mean-domain requirement.
Check. The canonical-link result satisfies \(-1/2=-0.5\). The log-link result satisfies \(\log(0.6065)\approx-0.5\).
Common mistake avoided: calling the Gamma log link canonical simply because it is familiar and produces positive fitted means. Positivity makes it usable here; it does not make it equal to the natural parameter.
Why Canonical Links Simplify the Score
The canonical link’s main algebraic advantage follows from the relationship between the natural parameter and the mean. For independent observations with common dispersion, write \(V(\mu)=b''(\theta)\), so that \(\operatorname{Var}(Y)=a(\phi)V(\mu)\). With \(\eta_i=x_i^\mathsf{T}\beta\), the chain rule gives the likelihood score for \(\beta\):
To see why this expression simplifies for a canonical link, differentiate the mean with respect to the natural parameter. Since \(\mu=b'(\theta)\), \(d\mu/d\theta=b''(\theta)=V(\mu)\). If the link is canonical, \(\eta=\theta\), and therefore \(d\mu/d\eta=V(\mu)\). Substituting this derivative cancels the variance function in the denominator:
This result assumes the exponential-family model and predictor stated above, with the same dispersion factor in the observations. It does not imply that every fitted coefficient has a simple closed-form solution; the fitted means still depend on \(\beta\), and the score equations may require numerical estimation. With a noncanonical link, \(d\mu/d\eta\) generally does not equal \(V(\mu)\), so this particular cancellation does not occur.
Worked Example: Applying the Canonical Poisson Score
A hypothetical count model has two independent Poisson observations, with predictors \(\eta_i=\beta_0+\beta_1x_i\). At a trial coefficient vector, \(\beta_0=\log 2\), \(\beta_1=\log 2\), and the observed data are \((x_1,y_1)=(0,3)\) and \((x_2,y_2)=(1,2)\). Calculate the score components at this trial vector. Name the method and a common mistake it avoids.
Method: use the canonical-link score for a Poisson GLM. The Poisson log link is canonical, and \(a(\phi)=1\). For observation 1, $$ \eta_1=\log 2+(\log 2)(0)=\log 2, \qquad \mu_1=e^{\eta_1}=2. $$ For observation 2, $$ \eta_2=\log 2+(\log 2)(1)=\log 4, \qquad \mu_2=e^{\eta_2}=4. $$ The residuals are \(y_1-\mu_1=3-2=1\) and \(y_2-\mu_2=2-4=-2\). Thus $$ \frac{\partial\ell}{\partial\beta_0} =(1)+(-2)=-1, \qquad \frac{\partial\ell}{\partial\beta_1} =(0)(1)+(1)(-2)=-2. $$ The score vector is \((-1,-2)^\mathsf{T}\). It is not zero, so this trial coefficient vector is not a likelihood stationary point.
Check. The intercept score sums both residuals. The slope score weights each residual by its \(x_i\); the first observation contributes zero because \(x_1=0\).
Common mistake avoided: inserting an extra factor of \(\mu_i\) into the Poisson score. In the general score, the Poisson variance function is \(V(\mu)=\mu\), while \(d\mu/d\eta=\mu\) for the log link. These factors cancel, leaving the residual contribution \(y_i-\mu_i\).
Choosing and Checking a Link
Canonical links are often convenient because they connect the predictor directly to the natural parameter and simplify likelihood calculations. A noncanonical link may nevertheless be useful when it gives an appropriate mean structure or makes the fitted means easier to interpret. In either case, check the model’s response distribution, the link definition, and the range of the inverse link before interpreting a fitted value.
For actuarial work, confusing a link with the response distribution can produce a wrong variance or an invalid mean. A Gamma log-link model still has the Gamma variance relationship \(\phi\mu^2\); using a log link does not turn it into a Poisson model. Likewise, using a canonical link does not establish that the distributional assumptions fit the data.
State the assumed distribution and its mean-variance relationship.
Express the distribution in exponential-family form, or use the corresponding standard representation.
The link is canonical when \(g(\mu)=\theta\), subject to the stated sign convention.
Confirm that the inverse link returns a mean allowed by the response distribution.
Check Your Understanding
For each problem, identify the link relationship and work through the requested calculation.
- A hypothetical Poisson count model has predictor \(\eta=\log 3\). Find its fitted mean and variance, and state whether the log link is canonical. (Answer: mean \(3\), variance \(3\), canonical.)
- A Gamma severity model uses variance \(\phi\mu^2\), with \(\phi=0.09\), and signed inverse-link predictor \(\eta=-0.25\). Find the mean and variance. (Answer: mean \(4\), variance \(1.44\).)
- A Gamma model has \(\eta=\log 5\) under a log link and dispersion \(\phi=0.04\). Find the fitted mean and variance, and classify the link. (Answer: mean \(5\), variance \(1\), noncanonical.)
- For one Poisson observation, \(y=1\) and \(\eta=\log 2\) under the canonical log link. Find the score contribution for an intercept-only predictor. (Answer: \(y-\mu=1-2=-1\).)
- A Gamma model is written with natural parameter \(\theta=-1/\mu\). A proposed link is \(g(\mu)=1/\mu\). Explain how it relates to the canonical link and whether it is usable for positive means. (Answer: it is the positive inverse form, differing by a sign from \(\theta\); it is usable for positive means when the predictor parameterization accounts for that sign.)