Statistical Calculators › Cluster Randomized and Multi-Level Designs › Cluster Randomized Trial Sample Size (Binary Outcome)
← All Calculators

Cluster Randomized and Multi-Level Designs

Cluster Randomized Trial Sample Size (Binary Outcome)

Calculate the number of clusters required per arm for a two-group cluster randomized trial with a binary outcome. The calculation uses the unpooled large-sample Z-test, average cluster size, and intracluster correlation coefficient (ICC), following the formulation documented in the statistical literature and attributed to Donner & Klar (2000).

Trial Design Inputs

Specify the expected binary outcome rates, clustering, and desired operating characteristics.

Required Sample Size

Equal allocation to two arms; clusters are the unit of randomization.
Enter the design parameters and click Calculate Sample Size.

Methodology

This calculator implements the large-sample unpooled Z-test approach for a two-arm parallel cluster-randomized trial with a binary outcome. This method uses this procedure as being based on the formulation of Donner and Klar (2000). The calculation assumes approximately equal cluster sizes and equal numbers of clusters in the two treatment groups.

Individual-randomization sample size

First, the required number of individuals per arm under individual randomization is calculated from the two expected proportions:

n = [(z1−α/2 + z1−β)² × {P1(1−P1) + P2(1−P2)}] / (P1 − P2

Here, P1 and P2 are the anticipated treatment and control proportions, α is the two-sided Type I error rate, and 1−β is the target power.

Inflation for clustering

Subjects within the same cluster are correlated, so the individually randomized sample size is inflated by the standard cluster design effect:

DE = 1 + (M − 1)ρ

where M is the average number of subjects per cluster and ρ is the intracluster correlation coefficient. this method describes this factor as the inflation factor and notes that the formulation assumes equal cluster sizes; when cluster sizes are approximately similar, their average may be used.

Clusters per arm

The inflated number of individuals per arm is divided by the number of subjects per cluster. Because a whole number of clusters is required, the result is rounded upward:

K = ceil{ n × DE / M }

The calculator then reports K clusters per arm, 2K total clusters, M subjects per cluster, and the resulting total number of subjects. It also computes the achieved power at the rounded cluster count so that the effect of rounding can be seen directly.

Assumptions and scope

This implementation is intended for a simple two-arm, parallel cluster-randomized design with approximately equal cluster sizes, equal cluster allocation, a binary outcome, and an unpooled large-sample Z-test. It does not implement stepped-wedge designs, matched-pair cluster randomization, unequal allocation, unequal cluster-size corrections, non-inferiority/equivalence margins, or mixed-effects logistic-regression-specific sample-size methods.

Validation Example

The implementation was checked against Example 3 in the relevant methodological literature for “Tests for Two Proportions in a Cluster-Randomized Design.” The documented inputs are P1 = 0.51, P2 = 0.44, two-sided α = 0.05, target power = 0.90, average cluster size M = 300, and ICC = 0.01. This yields 15 clusters per arm, 30 clusters total, 4,500 subjects per arm, 9,000 subjects total, with achieved power of 0.91574.

Validation target: K = 15 clusters/arm
this method achieved power: 0.91574
Clinical Biostats calculation: K = 15 clusters/arm; achieved power ≈ 0.91574

References

Donner, A. & Klar, N. (2000). Design and Analysis of Cluster Randomization Trials in Health Research. Arnold, London.

the software / this method. Tests for Two Proportions in a Cluster-Randomized Design, this method Sample Size Software documentation, Chapter 230. The documentation states that its formulation comes from Donner and Klar (2000), describes the cluster inflation factor 1 + (M−1)ρ, and provides the worked validation examples used here.

Hayes, R. J. & Moulton, L. H. (2017). Cluster Randomised Trials, 2nd ed. Chapman & Hall/CRC.