The implementation of the exact analytical solution of the Known Population Median Test involves approximations using the Stirling series and is therefore suspect for computational error. This function creates a population and empirically computes p-values via resampling. It then compares these empirical p-values to those calculated by the Known Population Median Test, and returns the error in log(p). WARNING! Takes a long time.
validate_accuracy(N = 50, n = 10, nrep = 1e+08)
population size
sample size
number of resampling samples for empirically estimating p-values.
data frame with log(p) error and other information.