1
$\begingroup$

I have a data set which involves 30 binomial absence/presences totalled for a ratio out of 1, which is the total score of a test out of 30 marks. The data requires fitting one of my predictor variables as a random effect,

glmer1 <- glmer(formula= cbind(NumberPresent, NumberAbsent) ~ Year + 
   Class + Gender + (1|School), data = Framework1, 
   family = "binomial"(link="logit"))

summary(glmer1) gives

AIC  4112.8     
BIC 4135.9
logLik -2051.4
deviance 4102.8
df.resid 732 

Obviously the data is still overdispersed after the inclusion of a random effect. My question is: Should i use a GLM with quasibinomial? Or stay with glmer with the random effect? Or is there a better way to do it?

Also: I get this error returned when i try to run the glmer.

Model is nearly unidentifiable: very large eigenvalue
 - Rescale variables?
Model is nearly unidentifiable: large eigenvalue ratio
 - Rescale variables?

Is this because of the nature of my variables?

$\endgroup$
1
$\begingroup$

There's a lot on this in the relevant section of the GLMM FAQ: briefly, the three simplest approaches are to:

  • get the equivalent of a quasibinomial model by first fitting the model and adjusting the standard errors etc. post hoc (there's code on the GLMM FAQ to do this);
  • fit a compound model (Beta-binomial) — although you'll have to switch to glmmTMB or some other package to do it
  • add an observation-level random effect (technically, a "logit-Normal-binomial compound model")

As for the rescaling: hard to know without seeing your data, but guessing that your problem is either (1) you're treating Year as a numeric variable and haven't rescaled or centered it; or (2) you have complete separation.


Harrison, Xavier A. 2015. “A Comparison of Observation-Level Random Effect and Beta-Binomial Models for Modelling Overdispersion in Binomial Data in Ecology and Evolution.” PeerJ 3 (July): e1114. https://doi.org/10.7717/peerj.1114.

$\endgroup$
2
  • $\begingroup$ Thank you very much for your response, very clear and helpful. I now understand and have worked around the problem. $\endgroup$ – sinsam23 Jun 19 '20 at 16:04
  • $\begingroup$ OK: if this solves your problem you are encouraged to click the check-mark to accept the answer ... $\endgroup$ – Ben Bolker Jun 19 '20 at 17:32

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.