An R package to create and visualize Fast and Frugal decision trees (FFTrees) like this one below:
# Create the trees titanic.fft <- FFTrees(formula = survived ~., data = titanic) # Plot the best tree plot(titanic.fft, main = "Surviving the Titanic", decision.names = c("Died", "Survived"))
Changed wording of statistics throughout package.
hr (hit rate) and
far (false alarm rate) are now
sens for sensitivity, and
spec for specificity (1 - false alarm rate)
rank.method argument is now depricated. Use
stats argument to
stats = FALSE, only the tree will be plotted without reference to any statistical output.
Grouped all competitive algorithm results (regression, cart, random forests, support vector machines) to the new
x.fft$comp slot rather than a separate first level list for each algorithm. Also replaced separate algorithm wrappers with one general
comp.pred() wrapper function.
FFForest(), a function for creating forests of ffts, and
plot.FFForest(), for visualizing forests of ffts. This function is very much still in development.
Added random forests and support vector machines for comparison in
FFTrees() using the
Changed logistic regression algorithm from the default
glm() version to
glmnet() for a regularized version.
predict.FFTrees() now returns a vector of predictions for a specific tree rather than creating an entirely new FFTrees object.
You can now plot cue accuracies within the
plot.FFTrees() function by including the
plot.FFTrees(what = 'cues') argument. This replaces the former
Many cosmetic changes to
plot.FFTrees() (e.g.; gray levels, more distinct classification balls). You can also control whether the results from competing algorithms are displayed or not with the
Trees can now use the same cue multiple times within a tree. To do this, set
rank.method = "c" and
repeat.cues = TRUE.
FFTrees() now supports a single predictor (e.g.;
formula = diagnosis ~ age) which previously did not work.
print.FFTrees()method to see important info about an FFTrees object in matrix format.
Training and testing statistics are now always in seperate objects (e.g.;
data$test) to avoid confusion.
predict.FFTrees()now works much better by passing a new dataset (
data.test) as a test dataset for an existing FFTrees object.
layoutare now reset after running
treeto conform to blog posts.
predict.FFTrees()now works better with
FFTreesthroughout the package to avoid confusion with fast fourier transform. Thus, the main tree building function is now
FFTrees()and the new tree object class is