exact_binom: Sample size for exact, one sample binomial test

Description Usage Arguments References Examples

View source: R/RcppExports.R

Description

Estimates sample size required to detect difference from a constant proportion.

Usage

1
2
3
4
5
6
7
exact_binom(
  constant_prop,
  effect_size,
  alpha = 0.05,
  power = 0.8,
  two_tail = TRUE
)

Arguments

constant_prop

The proportion under the null hypothesis.

effect_size

Positive size of the difference between your null hypothesis and the alternative hypothesis that you hope to detect. Heads-up that values less than 1% might take a while to calculate.

alpha

Probability of rejecting the null hypothesis even though it is true.

power

Probability of rejecting the null hypothesis (getting a significant result) when the real difference is equal to the minimum effect size.

two_tail

Whether to perform two-tail or one-tail power analysis. TRUE (default) tests in both directions of difference.

References

Power analysis and Exact test of goodness-of-fit from John H. McDonald's Handbook of Biological Statistics

Examples

1
exact_binom(0.75, 0.03)

wikimedia/wikimedia-discovery-ortiz documentation built on Aug. 23, 2020, 9:46 a.m.