rss: rss

Description Usage Arguments Value Note Examples

Description

A function that gives returns the RSS of a decision tree model.

Usage

1
rss(x)

Arguments

x

A fitted rpart, gbm, or rf model

Value

The Residuals Sums of Squares (RSS) for the models 'rpart', 'gbm.step', and 'randomForest'.

Note

when using the 'caret' package, be sure to select 'model$finalModel' when entering it into the 'rss' function. Also note that the RSS only works for continuous variables.

Examples

1
2
3
4
5
library(rpart)

fit.rpart <- rpart(Kyphosis ~ Age + Number + Start, data = kyphosis)

rss(fit.rpart)

njtierney/neato documentation built on May 23, 2019, 8:22 p.m.