Dear all, I am running a gls and I would like to check the vif of my model. It seems that the vif function in the car package and the vif.mer function available online do not work for gls. Would you know of a method to measure variance inflation factors for GLS? Thank you Laura [[alternative HTML version deleted]]
Dear Laura, There is no car::vif() method for gls objects, but the approach that car:::vif.lm() uses -- to compute VIFs (and generalized VIFs) from the correlation matrix of the coefficients -- should be applicable to models fit by gls(). I'll take a look a providing a vif.gls() method when I have some time, but, especially if you want VIFs, as opposed to GVIFs, you should be able to do the computations yourself. I hope this helps, John ------------------------------------------------ John Fox, Professor McMaster University Hamilton, Ontario, Canada http://socserv.mcmaster.ca/jfox/ On Tue, 20 May 2014 13:26:58 +0000 Laura Riggi <laura.riggi at slu.se> wrote:> Dear all, > I am running a gls and I would like to check the vif of my model. It seems that the vif function in the car package and the vif.mer function available online do not work for gls. Would you know of a method to measure variance inflation factors for GLS? > Thank you > Laura > > > > [[alternative HTML version deleted]] > > ______________________________________________ > R-help at r-project.org mailing list > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide http://www.R-project.org/posting-guide.html > and provide commented, minimal, self-contained, reproducible code.
Dear Laura, I've modified vif() in the development version of the car package on R-Forge so that it works with a wider variety of models, including gls models. Once the package is built on R-Forge, which usually takes about a day, you can install it via install.packages("car", repos="http://R-Forge.R-project.org"). Eventually, the development version of the car package will be moved to CRAN. Best, John> -----Original Message----- > From: r-help-bounces at r-project.org [mailto:r-help-bounces at r- > project.org] On Behalf Of Laura Riggi > Sent: Tuesday, May 20, 2014 9:27 AM > To: r-help at R-project.org > Subject: [R] Variation Inflation factor for GLS > > Dear all, > I am running a gls and I would like to check the vif of my model. It > seems that the vif function in the car package and the vif.mer function > available online do not work for gls. Would you know of a method to > measure variance inflation factors for GLS? > Thank you > Laura > > > > [[alternative HTML version deleted]] > > ______________________________________________ > R-help at r-project.org mailing list > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide http://www.R-project.org/posting- > guide.html > and provide commented, minimal, self-contained, reproducible code.