[R-sig-ME] lmer or glmer?

Michael Jackson Michael.Jackson at vuw.ac.nz
Sun Jan 11 21:58:43 CET 2015

Hi Ben,

Im wondering if you can help - ive been going round in circles for some weeks now and busily getting more bamboozled. Im basically wanting to use model selection (AICc scores, deltas etc) based on "lme4" outputs to identify the key nutritive drivers of animal consumption. Ive attached my data for you as I think it'll help greatly in showing my issues....My questions are...

1) Should I use REML=FALSE if wanting to compare mixed effects models via their AICc scores, deltas etc. where the random effects are always incorporated, but the fixed effects change between models. Everything ive read suggests yes...do you agree?

2) Ive got 14 different models to run - some additive, some interactive...an example of my code is as follows
m2 = lmer(Consumption ~ Fat + Protein + (1|Product/Trial), data=mydata, REML=FALSE)
m3 = lmer(Consumption ~ Sugars * Fat + (1|Product/Trial), data=mydata, REML=FALSE)

However - no matter which model I run and/or how I scale or transform my variables (both predictor and response) a shaprio wilks test, for example  shapiro.test(resids(m2)) is always significant ....Would using "glmer" be my option here? After reading your paper "Generalised linear mixed models: a practical guide for ecology and evolution" and this article on stackexchange<http://stackoverflow.com/questions/25356633/error-message-when-performing-gamma-glmer-in-r-pirls-step-halvings-failed-to-re>....Would the following example code be OK based on my raw untransformed data?

glmer(Consumption ~ Fat + Protein + (1|Product/Trial), data=mydata, family=Gamma(link=log))

Id value your comment and assistance as I dont want create loads of models and then make incorrect inferences of my AICc outputs based on flawed regression outputs...

Thanks in advance

PhD Candidate
Centre for Biodiversity and Restoration Ecology
Room KK 411
Kirk Building
Kelburn Parade
Wellington 6012

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