View source: R/average_power.R
average.power.t.test | R Documentation |
Compute average power of many t-tests; Uses classical power formula for t-test; Assumes equal variance and sample size
average.power.t.test(
n,
alpha,
delta,
sigma = 1,
type = "two.sample",
alternative = "two.sided"
)
n |
per-group sample size (scalar) |
alpha |
p-value threshold (scalar) |
delta |
difference of population means (vector) |
sigma |
standard deviation (vector or scalar, default=1) |
type |
type of t-test: "two.sample", "one.sample" |
alternative |
one- or two-sided test |
Average power estimate for multiple testing procedure
d = rep(c(2,0),c(100,900));
average.power.t.test(n = 20, alpha = 0.05,delta = d)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.