Create Split Labels For an Rpart Object

Usage

labels.rpart(object, pretty=T, collapse=T)

Arguments

object fitted model object of class rpart. This is assumed to be the result of some function that produces an object with the same named components as that returned by the rpart function.
pretty an integer denoting the extent to which factor levels will be abbreviated in the character strings defining the splits; (0) signifies no abbreviation of levels. A NULL signifies using elements of letters to represent the different factor levels. The default (T) indicates the maximum possible abbreviation.
collapse logical. If TRUE (default), the returned value is a vector of labels for each node, otherwise a matrix of left and right split labels is returned.

Value

Vector of split labels (collapse=T) or matrix of left and right splits (collapse=F) for the supplied rpart object. This function is called by printing methods for rpart and is not intended to be called directly by the users.

See Also

abbreviate


[Package Contents]