RF2List | R Documentation |
Transform a random forest object to a list of trees
RF2List(rf)
rf |
random forest object |
a list of trees
GBM2List
library(RRF)
data(iris)
X <- iris[,1:(ncol(iris)-1)]
target <- iris[,"Species"]
rf <- RRF(X,as.factor(target),ntree=100) # build an ordinary RF
treeList <- RF2List(rf)
ruleExec <- extractRules(treeList,X) # transform to R-executable rules
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.