mcrd_power: Perform a power analysis of a randomization test

Description Usage Arguments Author(s) Examples

Description

Note this is a convenience wrapper for mcr_power in the case of two sample differences

Usage

1
2
mcrd_power(generate_sample1, generate_sample2, ..., test_trials = 100,
  power_trials = 100)

Arguments

generate_sample1

a function returning a dataframe matching structure expected by statistics

generate_sample2

...

expressions to evaluate data produced by sample generating functions

test_trials

the number of MC trials to be performed per experiment

power_trials

the number of experiments to be performed in the power calculation

Author(s)

kholub

Examples

1
2
3
4
5
gen_data_s1 <- function(){ data.frame(x = rnorm(50), class = 'a') }
gen_data_s2 <- function(){ data.frame(x = rnorm(50, 1), class = 'b') }
mcrp <- mcrd_power(gen_data_s1, gen_data_s2, mean = mean(x), median = median(x), 
                   test_trials = 1e2)
mcrp

holub008/nymph documentation built on June 4, 2019, 10:47 a.m.