power_binomial: Power Calculation for the Chi-Square Test

Description Usage Arguments Details Value Examples

View source: R/n_chisq.R

Description

power_chisq performs the power calculation for two independent samples with binary data using the absolute rate difference quantifying the effect of an intervention. The method used here is based on the pages 21 - 26 in [1].

Usage

1
power_binomial(p_Y, p_X, n_Y, n_X, alpha, power.exact)

Arguments

p_Y

Event rate of group Y on the alternative.

p_X

Event rate of group X on the alternative.

n_Y

Sample size of group Y.

n_X

Sample size of group X.

alpha

Significance level α.

power.exact

If set to FALSE an approximative distributive is used for calculating the power, given the alternative distribution at the bottom of p. 22 in [1]. On TRUE the iterative approach is used.

Details

[1] M.Kieser: Fallzahlberechnung in der medizinischen Forschung [2018], 1th Edition

Value

power_binomial returns the power.

Examples

1
power_binomial(p_Y = .5, p_X = .3, n_Y = 100, n_X = 50, alpha = .05, power.exact = TRUE)

goseberg/samplesizr documentation built on May 28, 2019, 8:43 a.m.