Solution (source code)

= Solution

These are nested <Poisson regression> models with <independent> counts and the default log <link function>. If $x_i$ is biomass and $g_i$ is the three-level pH group, model 1 specifies $\log\mu_i=\alpha+\beta x_i$: one common intercept and slope. Model 2 specifies $\log\mu_i=\alpha_{g_i}+\beta x_i$: three group-specific intercepts and a common slope. Model 3 specifies $\log\mu_i=\alpha_{g_i}+\beta_{g_i}x_i$: three intercepts and three slopes, because the multiplication syntax includes both main effects and their interaction. The parameter counts are therefore $2,4,6$.

The <analysis of deviance> compares model 1 against model 2 by testing equality of the three intercepts, conditional on a common biomass slope. The <likelihood-ratio test> statistic is $407.67-99.24=308.43$ with two additional parameters, giving the reported tiny <p-value>. The next test compares model 2 against model 3 by testing equality of their three slopes. Its statistic is $99.24-83.20=16.04$, again with two degrees of freedom and reported $p=3.288\times10^{-4}$. Both restrictions are rejected. Thus \b[model 3 is the supported choice: both baseline richness and its biomass dependence vary with pH]. Under the Poisson assumptions, residual deviance $83.20$ on $84$ residual degrees of freedom is also consistent with a satisfactory fit, although these nested tests themselves establish improvement rather than every possible aspect of model adequacy.

The prediction from model 2 is on its linear-predictor scale. Exponentiating gives its fitted means. The final expression is twice the saturated log likelihood minus the model-2 log likelihood, i.e. the <Poisson deviance> of model 2. Consequently
$$
\boxed{\text{The returned value is }99.24\text{, up to the table's rounding}.}
$$
In the saturated model each mean equals the corresponding observed count, with the usual continuous convention for a zero count.