[R] Help converting SAS Proc mixed to R code

RKinzer ryank at nezperce.org
Thu Apr 14 21:12:46 CEST 2011


To anyone that may be able to help,

First I applogize if this message ends up in your inbox twice.  The first
one seemed to get stuck in a pending status so I deleted and started over.

I am relatively new to R, however I know the basics through some classes I
have taken.  Unfortunately the classes left off the more complicated
analysis that I need to learn and use.  I am attempting to replicate a SAS
mixed model in R to help me better understand the analysis, and I am having
trouble converting the code or getting the same results.  If anyone could
translate the following code into R I would appreciate at.

SAS Code:
Proc mixed method=ml
Class Group Treatment Stream Time Year;
Model logrkm=Treatment Time Treatment*Time;
Random Group Stream (Group Treatment) Year(Time);

I am trying to use:
prototype<-nlme(logrkm~Treatment+Time+Treatment*Time,
random=Stream+Group+Year)

I am lost, thanks for the help!

Ryan

--
View this message in context: http://r.789695.n4.nabble.com/Help-converting-SAS-Proc-mixed-to-R-code-tp3450484p3450484.html
Sent from the R help mailing list archive at Nabble.com.



More information about the R-help mailing list