crt.parallel.cont: Power for cluster randomized trial with continuous outcome

crt.parallel.contR Documentation

Power for cluster randomized trial with continuous outcome

Description

This function performs power and sample size calculations for a two-arm cluster randomized trial with a continuous, normal outcome. Can solve for power, J1, J.ratio, m or alpha.

Usage

crt.parallel.cont(
  m = NULL,
  m.sd = 0,
  J1 = NULL,
  J.ratio = 1,
  delta = NULL,
  sd = 1,
  icc1 = 0,
  icc2 = 0,
  ncov = 0,
  RsqB = 0,
  RsqW = 0,
  alpha = 0.05,
  power = NULL,
  sides = 2,
  v = FALSE
)

Arguments

m

The number of subjects per cluster or the mean cluster size (if unequal number of participants per cluster).

m.sd

The standard deviation of cluster sizes (provide if unequal number of participants per cluster); defaults to 0.

J1

The number of clusters in arm 1.

J.ratio

The ratio J2/J1 between the number of clusters in the two arms; defaults to 1 (equal clusters per arm).

delta

The difference between the intervention and control means under the alternative minus the difference under the null hypothesis.

sd

The total standard deviation of the outcome variable; defaults to 1.

icc1

The intraclass correlation coefficient in arm 1; defaults to 0.

icc2

The intraclass correlation coefficient in arm 2; defaults to 0.

ncov

The number of cluster-level and individual-level covariates; defaults to 0.

RsqB

The estimated proportion of total variance explained by cluster-level covariates; defaults to 0.

RsqW

The estimated proportion of total variance explained by individual-level covariates; defaults to 0.

alpha

The significance level (type 1 error rate); defaults to 0.05.

power

The specified level of power.

sides

Either 1 or 2 (default) to specify a one- or two- sided hypothesis test.

v

Either TRUE for verbose output or FALSE (default) to output computed argument only.

Value

A list of the arguments (including the computed one).

Examples

crt.parallel.cont(m = 30, J1 = 8, delta = 0.4, icc1 = 0.05, icc2 = 0.05)
crt.parallel.cont(m = NULL, J1 = 6, delta = 0.5, icc1 = 0.05, icc2 = 0.05, power = 0.8)
crt.parallel.cont(m = 25, m.sd = 15, J1 = NULL, delta = 0.3, icc1 = 0.05,
icc2 = 0.05, power = 0.8)
crt.parallel.cont(m = 20, J1 = 15, delta = 0.3, icc1 = 0.05, icc2 = 0.05,
RsqB = 0.1, ncov = 1, sides = 1)

powertools documentation built on April 4, 2025, 5:02 a.m.