fun.testboot | R Documentation |
Compare coverage of bootstrap confidence intervals.
fun.testboot( fcn, sampsize = 10, nsamp = NA, mcsamp = 10000, B = 9999, dists = c("rnorm", "rcauchy"), truem = NULL, alpha = 0.05 )
fcn |
function to be bootstrapped. |
sampsize |
Number of observations per sample; defaults to 10 |
nsamp |
Deprecated version of mcsamp. |
mcsamp |
Number of Monte Carlo samples. |
B |
Bootstrap size |
dists |
vector of names of random number generators for sample. Defaults to normal and Cauchy. This fails for a single distribution. |
truem |
True parameter value; should be of length 1 or length of distribution vector. |
alpha |
1-confidence level. |
A list with two components. The first is a two-dimensional array of average interval lengths. The second is coverage levels. Dimensions of both are distribution and confidence interval technique.
fun.testboot(function(x,indices) return(c(mean(x[indices]),1)),mcsamp=100,B=999)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.