srs_bootstrap: Performs a bootstrap assuming a simple random sample

Description Usage Arguments Value Examples

Description

Performs a bootstrap assuming a simple random sample

Usage

1
srs_bootstrap(dat, fun, replicates = 1000)

Arguments

dat

a data.frame

fun

a function taking a dataframe as a parameter

replicates

the number of replicates

Value

a list with class boot_est containing 'value': the value of the function applied to dat. 'var': the boostrap variance. 'replicates': The bootstrap values of fun. 'nrep': the number of replicates.

Examples

1
2
df <- data.frame(a=rnorm(100))
srs_bootstrap(df, colMeans,replicates=100)$var

ifellows/TestingHistoryIncidence documentation built on May 30, 2019, 8:04 p.m.