-----Original Message----- From:
r-sig-mixed-models-bounces at r-project.org on behalf of Alan Cobo-Lewis
Sent: Fri 12/19/2008 11:19 AM To: r-sig-mixed-models at r-project.org
Subject: Re: [R-sig-ME] heteroscedastic model in lme4
Anna,
lme4 cannot handle certain kinds of heteroscedasticity, but I believe
it can handle the kind you have in mind. Search the
r-sig-mixed-models archive for a discussion involving me and David
Afshartous, especially the summary message titled "[R-sig-ME] random
effect variance per treatment group in lmer" that David posted
07/13/2007 04:18:08 PM
I can't be certain that the suggestion below would work without
knowing more about your design, but if width were a factor with three
levels then you might try setting up indicator variables Wind1,
Wind2, and Wind3 (that each take on the value 1 when a site is at the
indicator's target width and 0 otherwise) and then fit the model with
something like mrem <- lmer( log(Nhat+1)~Group + GreenPerc + sess +
crop + VegDensity + Group:sess + Group:VegDensity + (0+Wind1|site) +
(0+Wind2|site) + (0+Wind3|site), data=all, method="REML" )
alan