[R-sig-ME] Error in LME4

Ben Bolker bbolker at gmail.com
Sun Jun 8 23:05:02 CEST 2014


On 14-06-08 04:08 PM, Hans Ekbrand wrote:
> On Sun, Jun 08, 2014 at 01:59:07AM +0530, Sunil Mundra wrote:
>> Hello all,I am new to use LME4 for analysing mixed effect model.I
>> am trying to test impact of Deep-snow treatment, sampling round,
>> and sampling depth on fungal richness.In my experiment:I have two
>> block (C and D), each Block has 3 fence group.I have two treatment
>> one is where snow is deep (causing soil warming) and other in
>> control sample, at each fence.Samples are collected 9 times in
>> summer from two different depth (2cm and 5cm).I hope i am able to
>> explain my experiment well... My first question the the model I am
>> using (see below) here, is OK for this question? Z1 <-
>> lmer(Richness ~ Treatment*Round*Depth +
>> (1|Block/Fence/Treatment/Round), REML= FALSE, data = data)
> 
> You don't need to specify wether your data is nested or crossed,
> lme4 will figure out that anyway. If you want random intercepts try:
> 
> Z1 <- lmer(Richness ~ Treatment*Round*Depth + (1|Block) + (1|Fence) +
> (1|Treatment) + (1|Round), REML= FALSE, data = data)
> 

  Minor correction here: lme4 can *only* figure out whether the grouping
variables are nested if they are uniquely labeled (e.g. fences within
block are labeled b1f1, b1f2, b1f3, b2f1, b2f2, b2f3, ... rather than
f1, f2, f3, f1, f2, f3 ...

> If you want random slopes, I think you need to explain what you want 
> better.
> 
> _______________________________________________ 
> R-sig-mixed-models at r-project.org mailing list 
> https://stat.ethz.ch/mailman/listinfo/r-sig-mixed-models
>



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