Millo Giovanni
2007-May-24 16:39 UTC
[R] lme with corAR1 errors - can't find AR coefficient in output
Dear List, I am using the output of a ML estimation on a random effects model with first-order autocorrelation to make a further conditional test. My model is much like this (which reproduces the method on the famous Grunfeld data, for the econometricians out there it is Table 5.2 in Baltagi): library(Ecdat) library(nlme) data(Grunfeld) mymod<-lme(inv~value+capital,data=Grunfeld,random=~1|firm,correlation=co rAR1(0,~year|firm)) Embarrassing as it may be, I can find the autoregressive parameter ('Phi', if I get it right) in the printout of summary(mymod) but I am utterly unable to locate the corresponding element in the lme or summary.lme objects. Any help appreciated. This must be something stupid I'm overlooking, either in str(mymod) or in the help files, but it's a huge problem for me. Thanks Giovanni Giovanni Millo Research Dept., Assicurazioni Generali SpA Via Machiavelli 4, 34131 Trieste (Italy) tel. +39 040 671184 fax +39 040 671160 Ai sensi del D.Lgs. 196/2003 si precisa che le informazioni ...{{dropped}}
Stephen Weigand
2007-May-25 18:48 UTC
[R] lme with corAR1 errors - can't find AR coefficient in output
Millo, On 5/24/07, Millo Giovanni <Giovanni_Millo at generali.com> wrote:> Dear List, > > I am using the output of a ML estimation on a random effects model with > first-order autocorrelation to make a further conditional test. My model > is much like this (which reproduces the method on the famous Grunfeld > data, for the econometricians out there it is Table 5.2 in Baltagi): > > library(Ecdat) > library(nlme) > data(Grunfeld) > mymod<-lme(inv~value+capital,data=Grunfeld,random=~1|firm,correlation=co > rAR1(0,~year|firm)) > > Embarrassing as it may be, I can find the autoregressive parameter > ('Phi', if I get it right) in the printout of summary(mymod) but I am > utterly unable to locate the corresponding element in the lme or > summary.lme objects. > > Any help appreciated. This must be something stupid I'm overlooking, > either in str(mymod) or in the help files, but it's a huge problem for > me. > >Try coef(mymod$model$corStruct, unconstrained = FALSE) Stephen -- Rochester, Minn. USA