[R-sig-eco] handling ca
Griffith.Michael at epamail.epa.gov
Griffith.Michael at epamail.epa.gov
Wed Aug 6 19:51:25 CEST 2008
In trying to use randomForest, I got the following error message:
Error in data.matrix(x) : non-numeric data type in frame
Am I correct that this means that randomForest has not be written in R
to handle categorical predictor variables? Is there a way around this?
I am working with two categorical variables (out of 4 predictor
variables) with more than 2 levels that do not have any particular order
to them. The instructions for the original random forest program by
Brieman indicates that it handles categorical predictor variables, so I
am surprised that the R version does not.
Michael
Michael B. Griffith, Ph.D.
Research Ecologist
USEPA, NCEA (MS A-110)
26 W. Martin Luther King Dr.
Cincinnati, OH 45268
telephone: 513 569-7034
e-mail: griffith.michael at epa.gov
More information about the R-sig-ecology
mailing list