Learn R Programming

PMCMRplus (version 1.9.12)

power.dunnett.test: Power Calculations for Balanced Dunnett's Many-to-One Comparison Test

Description

Compute average per-pair power of Dunnetts's multiple comparison test with one control.

Usage

power.dunnett.test(n, groups, delta, within.var, sig.level = 0.05)

Value

Object of class ‘power.htest’, a list of the arguments (including the computed one) augmented with method and note elements.

Arguments

n

Number of observations (per group)

groups

Number of groups (including control)

delta

true difference in means

within.var

Within group variance

sig.level

Significance level (Type I error probability)

Details

The function has implemented the following Eq. to estimate average per-pair power for two-sided tests:

$$ 1 - \beta = 1 - t( T_{\alpha \rho v}, v, \mathrm{ncp}) + t(-T_{\alpha \rho v}, v, \mathrm{ncp}), $$

with \(T_{\alpha \rho v}\) the two-sided \(\alpha\) quantile of the multivariate t-distribution, with \(v = k (n - 1)\) degree of freedom, \(k\) the number of groups and correlation matrix \(\rho_{ij} = 0.5 ~ (i \neq j)\).

The non-centrality parameter for the non-central student t-distribution is

$$ \mathrm{ncp} = |\Delta| / \sqrt{s_{\mathrm{in}}^2 ~ 2 / n }. $$

See Also

TDist qmvt powerMCTests

Examples

Run this code
set.seed(113)
power.dunnett.test(n = 9, groups = 5, delta = 30,
 within.var = 333.7)

## compare with t-test, bonferroni corrected
power.t.test(n = 9, delta = 30, sd = sqrt(333.7),
sig.level = 0.05 / 4)

if (FALSE) {
## asymptotic Monte-Carlo power analysis
 set.seed(113)
 powerMCTests(mu = c(rep(0,4), 30), n = 9,
 parms = list(mean = 0, sd = sqrt(333.7)),
 test = "dunnettTest", alternative = "two.sided")
}

Run the code above in your browser using DataLab