power.tukey.test: Power Calculations for Balanced Tukey's Multiple Comparison...

View source: R/power.tukey.test.R

power.tukey.testR Documentation

Power Calculations for Balanced Tukey's Multiple Comparison Test

Description

Compute average per-pair power of Tukey's test for multiple comparison of means.

Usage

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

Arguments

n

number of observations (per group)

groups

number of groups

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(q_{\alpha v k}/\sqrt{2}, v, \mathrm{ncp}) + t(-q_{\alpha v k}/\sqrt{2}, v, \mathrm{ncp}),

with q_{\alpha v k} the upper \alpha quantile of the studentised range distribution, with v = k (n - 1) degree of freedom and k the number of groups; and t(. ~\mathrm{ncp}) the probability function of the non-central student t-distribution with non-centrality parameter

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

Value

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

Source

The Eqs. were taken from Lecture 5, Determining Sample Size, Statistics 514, Fall 2015, Purdue University, IN, USA.

See Also

TDist Tukey powerMCTests

Examples

power.tukey.test(n = 11, groups = 5, delta = 30,
 within.var = 333.7)

## compare with t-test, Bonferroni-correction
power.t.test(n = 11, delta = 30, sd = sqrt(333.7),
sig.level = 0.05 / 10)

## Not run: 
powerMCTests(mu = c(rep(0,4), 30), n = 11,
 parms = list(mean = 0,sd = sqrt(333.7)),
 test = "tukeyTest")

## End(Not run)

PMCMRplus documentation built on Nov. 27, 2023, 1:08 a.m.