[R-sig-ME] single argument anova for GLMMs not yet implemented

Douglas Bates bates at stat.wisc.edu
Thu Dec 11 15:31:56 CET 2008


On Wed, Dec 10, 2008 at 9:56 AM, Ben Bolker <bolker at ufl.edu> wrote:
>
> R.S. Cotter wrote:
>> Dear all,
>>
>> Sorry if the question i stupid, I'm pretty new to this and have
>> googled, and tried the help in R without finding a answer.
>>
>> I have sucsessfully used glmm, lmer {lme4}, family binomial. By using
>> the summary (mod), I get the parameter estimates, but when using anova
>> (mod) I get this error message: Error in anova(mod) :  single argument
>> anova for GLMMs not yet implemented.
>>
>> I'm used to run lme {nlme} by using both summary () and anova (), is
>> that impossible when running glmm, lmer {lme4}?
>>
>> Thanks for help
>>
>
>  Not stupid.  (The only stupid questions are not-doing-your-homework
> ones.)
>
>  What information are you hoping to glean from anova(mod) ?
> If it is p-values for individual predictors, or information
> about "residual degrees of freedom", you're probably out of
> luck: see the oft-repeated questions on this list and the FAQ entry
> for why that's hard.
>
>  (Feel free to write back to clarify what you have in mind --
> but be warned that the answer is probably something along the
> lines of "lme4 doesn't work that way, you're still thinking
> in the classical sums-of-squares paradigm" ...)

I certainly agree with Ben that new users, or any users for that
matter, should feel free to ask questions about what does and doesn't
seem to work in the lme4 package.  The many kind users of the package
have been generous in allowing me to experiment in the code, sometimes
breaking features that were formerly working, while I try to come to
an understanding of mixed-effects models and computational methods for
them.  The process has worked in that I feel that I understand them
much better than I did in the past.  However, doing things the way I
do - creating and maintaining a software package that will allow for
fitting general versions of the model while I am still experimenting
with the overall design - is an intensive and, regrettably, slow way
of doing research.  My thanks to those who have had the tolerance to
take this journey with me.

The particular issue of not providing sequential anova summary for a
generalized linear mixed model is related to the "quasi" families of
conditional distributions.  Families like "binomial" or "poisson" or
"Gamma" or the default "gaussian" family (I find the capitalization of
those names to be interesting - the two proper nouns, Poisson and
Gaussian, are not capitalized and the common noun. gamma, is)
represent a probability distribution from which a likelihood can be
calculated.  The "quasi" families do not correspond to probability
distributions so they produce a quasi-likelihood which is used in the
GLM fitting.  I know how to add random effects to the linear predictor
for a model with a likelihood.  I'm not sure how it should be done for
the quasi families.  One can mimic the computations, but without a
sound theoretical basis, it is possible that the results could be
nonsense and I, at least, wouldn't know whether they were nonsense.

I may end up punting on the quasi families and simply provide some
parameter estimates without estimates of precision or, perhaps more
radically, not allow the quasi families to be used.  If you look at
the families provided in R you will see that the misleadingly named
"AIC" function in the family (it actually returns the deviance) is
only defined for binomial, Poisson, Gaussian and gamma families.
Those AIC functions evaluate probability densities or probability mass
functions and I can work with that.  I'm afraid I don't know enough
about the quasi families to make sense of them yet.




More information about the R-sig-mixed-models mailing list