bootstrap_performance {mikropml} | R Documentation |
Calculate a bootstrap confidence interval for the performance on a single train/test split
Description
Uses rsample::bootstraps()
, rsample::int_pctl()
, and furrr::future_map()
Usage
bootstrap_performance(
ml_result,
outcome_colname,
bootstrap_times = 10000,
alpha = 0.05
)
Arguments
ml_result |
result returned from a single |
outcome_colname |
Column name as a string of the outcome variable
(default |
bootstrap_times |
the number of boostraps to create (default: |
alpha |
the alpha level for the confidence interval (default |
Value
a data frame with an estimate (.estimate
), lower bound (.lower
),
and upper bound (.upper
) for each performance metric (term
).
Author(s)
Kelly Sovacool, sovacool@umich.edu
Examples
bootstrap_performance(otu_mini_bin_results_glmnet, "dx",
bootstrap_times = 10, alpha = 0.10
)
## Not run:
outcome_colname <- "dx"
run_ml(otu_mini_bin, "rf", outcome_colname = "dx") %>%
bootstrap_performance(outcome_colname,
bootstrap_times = 10000,
alpha = 0.05
)
## End(Not run)
[Package mikropml version 1.6.1 Index]