Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

plot.tree

Plot a Tree Object


Description

Plot a tree object on the current graphical device

Usage

## S3 method for class 'tree'
plot(x, y = NULL, type = c("proportional", "uniform"), ...)

Arguments

x

an object of class "tree".

y

ignored. Used for positional matching of type.

type

character string. If this partially matches "uniform", the branches are of uniform length. Otherwise they are proportional to the decrease in impurity.

...

graphical parameters.

Value

An (invisible) list with components x and y giving the coordinates of the tree nodes.

As a side effect, the value of type == "uniform" is stored in the variable .Tree.unif.? in the global environment, where ? is the device number.

Author(s)

B. D. Ripley

See Also


tree

Classification and Regression Trees

v1.0-40
GPL-2 | GPL-3
Authors
Brian Ripley [aut, cre]
Initial release
2019-03-01

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.