[R] relaimpo - dummy variable

Gabriela Bucini gbucini at nrel.colostate.edu
Fri Mar 19 20:48:33 CET 2010


Hi,

I have a question related to the function "boot.relimp" (package relaimpo).

I have a model with numerical predictors and one dummy (class) variable. I
would like to calculate the relative importance of the predictors but I have
some problems with the dummy variable.

The name of the linear model is "lmbroadst.lc" and the dummy variable is
"datacon.landcover_gb" (with 7 levels). I write the command as:

boot <- boot.relimp(lmbroadst.lc, b = 500, type = c("lmg", "last", "first"),
rank = TRUE, group = datacon.landcover_gb,
  diff = TRUE, rela = TRUE)

The error message is:

Error in boot.relimp.lm(lmbroadst.lc, b = 500, type = c("lmg", "last",  :
  argument 5 matches multiple formal arguments


What is the correct syntax to include the dummy variable?

Thank you very much for your help!

Gabriela Bucini



More information about the R-help mailing list