[R-sig-ME] Generalized least squares program

Steven McKinney smckinney at bccrc.ca
Wed Jul 16 19:29:16 CEST 2008


Hi Gang, 

Have you tried the predict() function?
You should be able to hand off new data
to your saved fitted model object.  
See 
?predict.gls
for an example.

HTH

Steve McKinney

-----Original Message-----
From: r-sig-mixed-models-bounces at r-project.org on behalf of Gang Chen
Sent: Wed 7/16/2008 8:21 AM
To: r-sig-mixed-models at r-project.org
Subject: [R-sig-ME] Generalized least squares program
 
I'm using function gls in nlme to run some extended linear model with  
generalized least squares many many times in a loop with the same  
design matrix X and same residual covariance structure but different  
values for the response variable. A lot of time is wasted in  
reformulating the same model structures and overhead matrix  
calculations. Such a waste makes the runtime range from one day to  
one month. Are there some slots available in gls that would allow me  
to avoid the unnecessary waste? If not, is there a counterpart of gls  
for extended linear model with generalized least squares available in  
lme4 that would give such slots?

Thanks,
Gang

_______________________________________________
R-sig-mixed-models at r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-sig-mixed-models




More information about the R-sig-mixed-models mailing list