Last chance! 50% off unlimited learning
Sale ends in
"histogram"(x, data = NULL, metric = x$metric, ...)
train
histogram
,
densityplot
,
xyplot
or
stripplot
train
object. The function trainControl
can be used
to save all the results (see the example below).If leave-one-out or out-of-bag resampling was specified, plots cannot be
produced (see the method
argument of trainControl
)
For xyplot
and stripplot
, the tuning parameter with the most
unique values will be plotted on the x-axis. The remaining parameters (if
any) will be used as conditioning variables. For densityplot
and
histogram
, all tuning parameters are used for conditioning.
Using horizontal = FALSE
in stripplot
works.
train
, trainControl
,
histogram
,
densityplot
,
xyplot
,
stripplot
## Not run:
#
# library(mlbench)
# data(BostonHousing)
#
# library(rpart)
# rpartFit <- train(medv ~ .,
# data = BostonHousing,
# "rpart",
# tuneLength = 9,
# trControl = trainControl(
# method = "boot",
# returnResamp = "all"))
#
# densityplot(rpartFit,
# adjust = 1.25)
#
# xyplot(rpartFit,
# metric = "Rsquared",
# type = c("p", "a"))
#
# stripplot(rpartFit,
# horizontal = FALSE,
# jitter = TRUE)
#
# ## End(Not run)
Run the code above in your browser using DataLab