[R] Summary: proc mixed vs. lme
Grathwohl,Dominik,LAUSANNE,NRC/NT
dominik.grathwohl at rdls.nestle.com
Wed Oct 9 20:19:37 CEST 2002
Summary: proc mixed vs. lme
The objective of this summary is to help people
to get more familiar with the specification of
random effects with proc mixed or lme.
Very useful are the examples of Ramon Littell's book:
"SAS System for Mixed Models (1996)"
(http://ftp.sas.com/samples/A55235)
The same data set's are kindly made available
by Douglas Bates in the library(SASmixed).
In the help file are examples of the lme statements
equivalent to the proc mixed ones.
To explain the different estimates,
Hein and Brian suppose to check whether both
analyses with SAS and R uses ML estimates
or REML estimates. However, this was not the problem,
the default in proc mixed and lme is already REML.
Douglas advise me to use his option:
options( contrasts = c(unordered = "contr.SAS",
ordered = contr.poly"))
However, I already used this option,
because I copied the code from the SASmixed help file.
Peter gave me the first hint
and this solves the problem:
To change the model formula in lme,
from: strength ~ Program * Time
to: strength ~ factor(Program) * factor(Time)
Now the option statement grasp!
For people like me who try to get familiar
with the specification of random effects
would it helpful if the help file of SASmixed
would be updated or the variables time and program
would be already introduced as factors
in the Weights data set.
Thank you all for the useful advises,
Dominik
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
More information about the R-help
mailing list