0

I am using R for creating a decision tree using CART. I did it using

feature_vectors <- read.table("C:/Users/DVS/Desktop/TagMe!-Data/Train/feature_vectors.txt", quote="\"")
set.seed(1234)
ind <- sample(2, nrow(winequality.red), replace=TRUE, prob=c(0.7, 0.3))
trainData <- winequality.red[ind==1,]
testData <- winequality.red[ind==2,]
myFormula <- quality ~ fixed.acidity + volatile.acidity + citric.acid + residual.sugar + chlorides + free.sulfur.dioxide + total.sulfur.dioxide + density + pH + sulphates + alcohol
table(predict(wine_ctree), trainData$quality)
print(wine_ctree)
plot(wine_ctree)

Now, I Need to Print a list of candidate attributes possible for Root node. ie node with minimal deviation in (im)purity values from Selected Root Node. Is there any way to use built in functions or do I have to modify the source?

4

0 に答える 0