Skip to content
Prev 267 / 7420 Next

multilevel mixed effects LME and LMER

First I would like to say thank you for taking the time to read it.

Here is my problem.
I did an experiment to access the impact of an invasive plant on mice behavior and abundacne. Basically  I  manipulated fruits and vegetation to two
levels each(present and absent) on 12 experimental plots The design consisted of  12 plots,
divided in 3 blocks.  So each block had 4 plots assigned to one of the
following treatments. 
Fruit intact and Vegetation intact 
Fruit intact and Vegetation removed 
Fruit removed and Vegetation intact 
Fruit removed and Vegetation removed 
Then I sampled mice activity by recording the presence or absence of paw prints on 16 track plates positioned on each plot. 
I also measured the number of trees on each plot and got their diameter. I created an index for tree cover and I want to use it as covariate. 
My goal is to determine how the interaction of fruits, vegetation, and time explain the mice behavior. 

Because my data is binary and I have fixed (fruit, veget, time) and random effects (block, and trackID as repeated measures) I am trying to fit a model using lmer. 
here is my first attempt
model<-lmer(track~veget*fruit*time*(time|plate)*(1|block),family=binomial)
 
My problem is that when I run this model I get more than 1000 degrees of freedom. Which does not make any sense, remember:
16 plates
2 levels for fruits
2 levels for veget
3 blocks
7 months (time)
so I don't know what it is going on. Should I group this by plot ID instead of plate?
check a sample of the data on the end.

Also, how do I fit a covariate in these model. Especially when it comes to data format. I have just one indez per plot, how do I add this to the model. Should I repeat the same value for all the 16 plates in that plot? 

Thank  you very much for any comments. 

  plate track time block   fruit   veget
==========================================================
'Discipline - Success doesn't just happen. You have to be intentional about it, and that takes discipline.' - John Maxwell