Skip to contents

Thin pass-through that computes bootstrap confidence intervals from a boot object via boot::boot.ci, returning a tidy named list with (ci_lower, ci_upper) per requested type.

Usage

morie_boot_basic_ci(
  boot_obj,
  type = c("perc", "bca", "basic", "norm"),
  conf = 0.95
)

Arguments

boot_obj

A boot object as returned by morie_boot_run() or boot::boot.

type

Character vector of CI types; any of "perc", "bca", "basic", "norm", "stud".

conf

Confidence level (default 0.95).

Value

Named list of length length(type); each element is a numeric length-2 vector c(ci_lower, ci_upper).

See also

Examples

set.seed(1)
b <- morie_boot_run(rnorm(50), statistic = mean, R = 200L)
morie_boot_basic_ci(b)
#> $perc
#> [1] -0.1263354  0.3119452
#> 
#> $bca
#> [1] -0.1338356  0.3082012
#> 
#> $basic
#> [1] -0.1110486  0.3272320
#> 
#> $norm
#> [1] -0.1206996  0.3312841
#>