View source: R/calculate_boot_stats.R
calculate_boot_stats | R Documentation |
A bootstrapped confidence interval for the desired estimator for
the provided sample is calculated for a confidence level level
.
Other stats and parameters of the distribution and sample are
also returned.
calculate_boot_stats( sample, rep, n = "auto", level = 0.95, estimator = "mean", seed = NULL, pass_dist = FALSE )
sample |
A numeric vector to bootstrap |
rep |
A integer vector for number of replicates |
n |
A integer or character vector for the size of bootstrap samples |
level |
A numeric vector for the confidence level |
estimator |
A character vector containing one of the ("mean", "median", "var", "sd") estimators |
seed |
A integer vector as random seed. Can be |
pass_dist |
A boolean vector to decide whether to return the bootstrapped distribution |
A named list
calculate_boot_stats(c(1, 2, 3, 4), 1000, level = 0.95, seed = 1) calculate_boot_stats(c(1, 2, 3, 4), 1000, level = 0.95, estimator = "median", seed = 1, pass_dist = TRUE)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.