Message-ID: <CACgv6yWeKyybJO6vOZM7B+RbxLSr3K75TdTUfoYrsHKXoS=NXQ@mail.gmail.com>
Date: 2020-10-03T16:44:36Z
From: Simon Harmel
Subject: Dropping correlations bet. random-effects in lme4 syntax
In-Reply-To: <06a872f4-a00f-ef39-ba88-5c147620039e@mpi.nl>
Thanks Phillip. What would be the meaning of placing `0 +` next to any of
the random effects (e.g., B) as shown in m2?
m1 <- lmer(y ~ A * B * C + (A * C | group) + (B|group) , data = data)
m2 <- lmer(y ~ A * B * C + (A * 0+ B * C | group), data = data)
On Sat, Oct 3, 2020 at 11:33 AM Phillip Alday <phillip.alday at mpi.nl> wrote:
> You can split the specification of your grouping to achieve this, at
> least in part:
>
> lmer(y ~ A * B * C + (A * C | group) + (B|group) , data = data)
>
> Note that life gets tricky with the interaction terms.
>
> Phillip
>
> On 03/10/2020 06:35, Simon Harmel wrote:
> > Hello all,
> >
> > I know to drop all correlations among all level-1 predictors in the
> random
> > part of an lmer() call, I can use `||`. But I was wondering how to drop
> > correlations (a) "individually" or (b) "in pairs"?
> >
> > Example of (a) is how to drop the correlation of B with others (A & C)?
> > Example of (b) is how to drop the correlation between B and C?
> >
> > lmer(y ~ A * B * C + (A * B * C || group), data = data)
> >
> > Thanks,
> > Simon
> >
> > [[alternative HTML version deleted]]
> >
> > _______________________________________________
> > R-sig-mixed-models at r-project.org mailing list
> > https://stat.ethz.ch/mailman/listinfo/r-sig-mixed-models
>
[[alternative HTML version deleted]]