Skip to contents

p_B = 1 - H_n(T_n) with H_n the bootstrap null cdf of the studentized statistic (null resampling from x - xbar + mu0); p_B1 is the fraction of outer resamples whose inner-prepivoted statistic H*_b(T*_b) is at least H_n(T_n) (double prepivoting).

Usage

morie_btiseq(x, mu0 = 0, B_outer = 300, B_inner = 150, seed = 0)

Arguments

x

Numeric sample.

mu0

Null mean value.

B_outer, B_inner

Bootstrap sizes.

seed

SplitMix64 seed (mirrors the Python arm).

Value

A list with elements statistic, p_boot, p_iterated, prepivoted_value, mu0, B_outer, B_inner, seed, method.

References

Beran, R. (1988). Prepivoting test statistics: a bootstrap view of asymptotic refinements. JASA, 83(403), 687-697.

Examples

# \donttest{
set.seed(1)
r <- morie_btiseq(x = rnorm(10)); TRUE
#> [1] TRUE
# }