Contains both 'fixed' and 'random' effects
This allows us to make the most of our data (better statistical power),
while also accounting for pseudoreplication and non-independence of data
GLMMs are most useful for correlation structures relating to discrete
data types (e.g. site), rather that continuous variables (e.g. time or distance)
lmer
model.names <- lmer(response ~ fixed.effects + (random.effects),
data, family, ...)
(1|site)
- site as a random factor
(1|site/quadrat)
- quadrants nested within sites
(1|site) + (1|year)
- two random factors (unnested)
AIC values in difference packages may not be directly comparable
due to differences in model fitting procedures (e.g. lme4 vs glmmADMB)
In the packages lme4
or nlme
:
ML
REML
MuMln
for automated model selection by AICFor non-linear responses, consider Generalised Additive Models (GAM/GAMM)
For specific temporal or spatial autocorrelation structures, consider: