[R] Using a covariance matrix as input to relaimpo package

Ku!Rt Kurt.Salmela at maritz.com
Tue Dec 16 21:56:40 CET 2008

By trial and error I have discovered that it works if I don't use the formula
interface in combination with a covariance matrix as input.

If the covariance matrix has the dependent variable as its left-most
variable as the relaimpo documentation suggests, then the relaimpo package
will run by simply naming the covariance matrix as the first object in the
call and not using a formula.  The downside of this is needing to create
different covariance matrices for different models.

The following will work:

# calculate covariance matrix from survey respondent data using pairwise
covmatrx =
use = "pairwise")

# try the lmg method of relative importance
> imps1 = calc.relimp(covmatrx, type="lmg", rela=TRUE)

View this message in context: http://www.nabble.com/Using-a-covariance-matrix-as-input-to-relaimpo-package-tp21022295p21041633.html
Sent from the R help mailing list archive at Nabble.com.

More information about the R-help mailing list