Syntax for linear mixed model

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Syntax for linear mixed model

N.W.Galwey
The syntax below works, and gives the expected results, in R version 2.0.0,
provided that I have loaded packages Matrix, latticeExtra and lme4.
However, I cannot get it to work in version 2.2.1.   Can anyone tell me how
to fit this model in the more recent version?

 

Thanks in anticipation,

 

Nick Galwey

 

barleyprogeny.model1lme <- lme(yield_g_m2 ~ 1,

   data = barleyprogeny.unbalanced, random = ~ 1|fline + fblock)

 


        [[alternative HTML version deleted]]

______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Reply | Threaded
Open this post in threaded view
|

Re: Syntax for linear mixed model

Dieter Menne
N.W.Galwey <nw.galwey <at> ukonline.co.uk> writes:

>
> The syntax below works, and gives the expected results, in R version 2.0.0,
> provided that I have loaded packages Matrix, latticeExtra and lme4.
> However, I cannot get it to work in version 2.2.1.   Can anyone tell me how
> to fit this model in the more recent version?
>
>
> barleyprogeny.model1lme <- lme(yield_g_m2 ~ 1,
>
>    data = barleyprogeny.unbalanced, random = ~ 1|fline + fblock)
>

You must use the new style and call lmer when using package lme4 now. There is
no full documentation on lmer yet since package lme4 is work in progress, but
there are a few examples in the MEMSS package.

However, I would suggest that for the rather simple model, you better don't
load lme4 and Matrix, and use well-documented package nlme instead.

Dieter

______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html