[R-sig-ME] Quasipoisson: alternative implementation
Gosselin Frederic
frederic.gosselin at cemagref.fr
Fri Feb 26 08:49:25 CET 2010
Dear Colleague,
it seems that quasi-poisson interests more and more R members...
To your question 1:
> 1) Is it common knowledge that the quasipoisson family incorrectly weights things somewhere in glmer? The example
>below gives a demonstration.
I answer again (cf. https://stat.ethz.ch/pipermail/r-sig-mixed-models/2010q1/003348.html and https://stat.ethz.ch/pipermail/r-sig-mixed-models/2009q4/003059.html) that quasi-poisson implemented in glmer/lmer - as well as quasibinomial - has a very strange behaviour as the one you report in latter versions of R but not in older ones (let's say before version 2.5.1). I reproduced your test under R2.2.1: here is the result, much better - note the slight difference in the syntax:
> lmer(x2 ~ 1+(1|z), family = "quasipoisson")
Generalized linear mixed model fit using PQL
Formula: x2 ~ 1 + (1 | z)
Family: quasipoisson(log link)
AIC BIC logLik deviance
188.8215 194.0318 -92.41075 184.8215
Random effects:
Groups Name Variance Std.Dev.
z (Intercept) 9.1691e-10 3.0280e-05
Residual 1.8338e+00 1.3542e+00
number of obs: 100, groups: z, 2
Fixed effects:
Estimate Std. Error t value
(Intercept) 4.621536 0.013432 344.08
Regarding your second suggestion, - including a innerlevel random effect - this is a different model, which is based on a "real" liklelihood, that might be worth considering, along e.g. negative binomial models in other R functions. Then, why not simply using:
ind <- factor(1:100)
glmer(x2 ~ (1|ind), family = poisson)
As you mention, you then cannot treat underdispersion, which might be a problem in some settings.
Sincerely,
Frédéric Gosselin
Engineer & Researcher (PhD) in Forest Ecology
Cemagref
Domaine des Barres
F-45290 Nogent sur Vernisson
France
http://www.cemagref.fr/les-contacts/les-pages-personnelles-professionnelles/gosselin-frederic/english-short-scientific-cv
More information about the R-sig-mixed-models
mailing list