[R] Using caegorical variables in package randomForest.

abhishek abhi_physics at hotmail.com
Tue Mar 13 13:10:51 CET 2012


Hello,

I am sorry if there are already post that answers to this question but i
tried to find them before making this post. I did not really find relevant
posts.

I am using randomForest package for building a two class classifier. There
are categorical variables and numerical variables in my data. Different
categorical variables have different number of categories from 2 to 10. I am
not sure about how to represent the categorical data.
For example, I am using 0 and 1 for variables that have only two categories.
But, i doubt, the program is analysing the values as numerical. Do you have
any idea how can i use the c*ategorical variables for building a two class
classifier.* I am using a factor consisting of 0 and 1 for the
classification target.

Thank you for your ideas.

-----
abhishek
--
View this message in context: http://r.789695.n4.nabble.com/Using-caegorical-variables-in-package-randomForest-tp4468923p4468923.html
Sent from the R help mailing list archive at Nabble.com.



More information about the R-help mailing list