[R-sig-ME] How to consider temporal autocorrelation in a GLMM

A Mauchamp @ndre@m@uch@mp @end|ng |rom protonm@||@com
Tue Jun 29 13:03:11 CEST 2021


I am currently analyzing (in R) ecological monitoring data that have 5 successive years, one point per year and multiple sites and replicates within sites. Having a combination of fixed (environmental variables) and random (sites) effects, I need to use mixed models.
Using glmer of the package lme4, I would like to account for the strong correlation between one year data and the following that I observe for most variables.
I found this idea here https://stackoverflow.com/questions/24452796/accounting-for-temporal-correlation-in-glmm which looks very simple and straightforward.
It would result in a formula as
y_t ~ env1 + env2 + env3 + y_t-1 + (1|site)
However in some cases, all environmental effects disappear and the only relation that remains is with y_t-1.

I also found this approach:
y ~ env1+ env2 + time + (1|replicate) + (1|site) that treats time as fixed effect and groups the repeated measures of replicates. Though I am not sure it is correct.

Would it be correct to use time as a random effect ?

Data are either count data (Poisson error distribution) or quantitative and gaussian.
Which would be the most appropriate way of dealing with such repeated measures /short time series ?
Which reference could I use to support the method ?
My data series is indeed to short to go for a real time-series analysis and I don't think I can go for more than one year lag.

Thank you for any suggestion,

Sent with [ProtonMail](https://protonmail.com/) Secure Email.
	[[alternative HTML version deleted]]

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