Description Usage Arguments Value Examples
View source: R/get_best_model_results.r
Extract best model performances
1 |
bmr |
A bmr object, result of the |
A dataframe containing the best model results (learner name, optimal iteration number and associated AUC).
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 | ## Not run:
# download benchmarking data
benchmarking_data <- get_benchmarking_data("Lynx lynx",
limit = 1500)
# create a list of algorithms to compare
learners <- list(mlr::makeLearner("classif.randomForest",
predict.type = "prob"),
mlr::makeLearner("classif.logreg",
predict.type = "prob"))
# run the model benchmarking process
bmr <- benchmark_sdm(benchmarking_data$df_data,
learners = learners,
dataset_type = "default",
sample = FALSE)
# get best model results
# you should obtain a dataframe containing the highest performing (by AUC)
# algorithm name, iteration and associated AUC
best_results <- get_best_model_results(bmr)
best_results
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.