Spatial AND temporal correlation in linear mixed-effects models
On 07/26/2012 10:45 AM, Tscheulin Thomas wrote:
Hi, I have a question regarding the nesting structure in linear mixed models of data, which is spatially and at the same time temporally correlated. So far I have tried to get around the problem by averaging out the temporal component but I would really like to keep everything in the model. Here is the experimental set-up: We have measured insect abundance in two different islands, each having 5 sites, each site having 4 plots, in which each we have 5 collection points (traps). The sampling was repeated 5 times. Two times in 2011 and 3 times in 2012. After averaging the temporal correlation out I composed the following model for the abundance: model<-lme(abundance~continous_explanatory_variable,random=~1|island/site/plot/trap,method="REML") This works fine but I have problems making a model that allows the temporal component to stay in. How can I do this using the function lme? I know with lmer I could do this: model2<-lmer(abundance~continous_variable+(1|island/site/distance/triplet)+(1|year/round)) but I really want to use the function lme. How can I insert multiple levels of grouping in lme? Any help is very much appreciated! Best,
A bit of googling brought up this, from 10 years ago: <http://tolstoy.newcastle.edu.au/R/help/02b/2068.html> I don't think lme has changed that much. Bob
Bob O'Hara Biodiversity and Climate Research Centre Senckenberganlage 25 D-60325 Frankfurt am Main, Germany Tel: +49 69 798 40216 Mobile: +49 1515 888 5440 WWW: http://www.bik-f.de/root/index.php?page_id=219 Blog: http://blogs.nature.com/boboh Journal of Negative Results - EEB: www.jnr-eeb.org