Dear R users,
I fitted a repeated measure model without random effects by using lme. I will
use the estimates from that model as an initial estimates to do multiple
imputation for missing values of the response variable in the model. I am
trying to extract the within group correlation matrix or covariance matrix.
here is my code:
f = lme(y ~x0+x1+trt+tim+x1:tim +tim:trt,random=~-1|subj, data=dat,corr
=corAR1())
> f$sigma
[1] 2.330854
b=summary(f)$modelStruct$corStruct
> b
Correlation structure of class corAR1 representing
Phi
0.8518711
I think 0.8518711 and f$sigma is what I need to reconstruct the
variance-cavariance matrix. So, How can I extract 0.8518711 so that I can
assign it to a variable? Also, I don't understand what the following parameters
estimates mean?
>summary(f)$modelStruct
reStruct parameters:
subj
-20.15833
corStruct parameters:
[1] 2.525869
I appreciate your time on this.
Best wishes,
Liqiu
---------------------------------
Rekindle the Rivalries. Sign up for Fantasy Football
[[alternative HTML version deleted]]
______________________________________________
[email protected] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html