[R] Chaid Decision Tree

MIKE DE LA HOZ miguelhoz at hotmail.com
Mon Aug 22 15:38:45 CEST 2016


I am running a chaid tree using titanic dataset (see attachment)


titanic <- read.csv("train.csv")
titanic.s <- subset( titanic, select = -c(PassengerId, Name ) )

ctrl <- chaid_control(minsplit = 20, minbucket = 5, minprob = 0)
chaidTitanic <- chaid(Survived ~ ., data = titanic, control = ctrl)

It looks like I get the following error

Error: is.factor(x) is not TRUE

can you please help me here? I am not able to follow this type of error. if you can rewrite the sentence for me, It will be much appreciated


More information about the R-help mailing list