plot.pre | R Documentation |
plot.pre
creates one or more plots depicting the rules in the final
ensemble as simple decision trees.
## S3 method for class 'pre'
plot(
x,
penalty.par.val = "lambda.1se",
gamma = NULL,
linear.terms = TRUE,
nterms = NULL,
fill = "white",
ask = FALSE,
exit.label = "0",
standardize = FALSE,
plot.dim = c(3, 3),
...
)
x |
an object of class |
penalty.par.val |
character or numeric. Value of the penalty parameter
|
gamma |
Mixing parameter for relaxed fits. See
|
linear.terms |
logical. Should linear terms be included in the plot? |
nterms |
numeric. The total number of terms (or rules, if
|
fill |
character of length 1 or 2. Background color(s) for terminal panels. If one color is specified, all terminal panels will have the specified background color. If two colors are specified (the default, the first color will be used as the background color for rules with a positively valued coefficient; the second color for rules with a negatively valued coefficient. |
ask |
logical. Should user be prompted before starting a new page of plots? |
exit.label |
character string. Label to be printed in nodes to which the rule does not apply (“exit nodes”)? |
standardize |
logical. Should printed importances be standardized? See
|
plot.dim |
integer vector of length two. Specifies the number of rows and columns in the plot. The default yields a plot with three rows and three columns, depicting nine baselearners per plotting page. |
... |
Arguments to be passed to |
pre
, print.pre
set.seed(42)
airq.ens <- pre(Ozone ~ ., data = airquality[complete.cases(airquality),])
plot(airq.ens)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.