Cluster Randomized and Multi-Level Designs
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).
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.
First, the required number of individuals per arm under individual randomization is calculated from the two expected proportions:
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.
Subjects within the same cluster are correlated, so the individually randomized sample size is inflated by the standard cluster design effect:
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.
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:
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.
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.
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.
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.