power.crt.test: Power calculations for simple cluster randomized trials

Description Usage Arguments Details Value Note Authors

Description

Compute the power of a simple cluster randomized trial, or determine parameters to obtain a target power.

Usage

1
2
power.crt.test(alpha = 0.05, power = 0.8, m = NULL, n = NULL, d = 0.2,
  ICC = NULL, cv = 0, tol = .Machine$double.eps^0.25)

Arguments

alpha

The level of significance of the test, the probability of a Type I error.

power

The power of the test, 1 minus the probability of a Type II error.

m

The number of clusters per condition. It should be greater than 1.

n

The mean cluster size, or a vector of cluster sizes with length equal to twice m.

d

The standardized effect size.

ICC

The intra-class correlation.

cv

The coefficient of variation. When cv = 0, the cluster all have the same size.

tol

Numerical tolerance used in root finding. The default provides at least four significant digits.

Details

Exactly one of alpha, power, d, ICC, m, n, and cv must be passed as NULL. Note that alpha, power, d, and cv have non-NULL defaults, so if those are the parameters of interest they must be explicitly passed as NULL.

Value

The computed argument.

Note

'uniroot' is used to solve power equation for unknowns, so you may see errors from it, notably about inability to bracket the root when invalid arguments are given.

Authors

Jonathan Moyer (jon.moyer@gmail.com), but this function is based on work by Peter Dalgaard (power.t.test) and Stephane Champely (pwr.t.test).


jm3594/crtpower documentation built on May 19, 2019, 12:48 p.m.