Machine Learning with caret in R
Max Kuhn
Software Engineer at RStudio and creator of caret
# Load some data
library(caret)
library(mlbench)
data(Sonar)
# Set seed
set.seed(42)
model <- train(
Class ~ .,
data = Sonar,
method = "ranger"
)
# Plot the results
plot(model)
Machine Learning with caret in R