Skip to main content

    Method document

    Sample size to compare two independent correlations

    How many participants are needed in each of two independent groups to show that the same correlation differs between them. Covers dropout.

    Engine version 1.0.0 · Reviewed 1 October 2026

    https://statwisely.com/methods/correlation-compare/

    When to use it

    • Testing whether an association is stronger in one population than another, such as in women and men.

    Not for

    • Two correlations measured on the same people, which are dependent and need a different test.

    Notation

    nn
    Participants per group
    r1, r2r_1,\ r_2
    Expected correlations in groups 1 and 2
    z(r)z(r)
    Fisher’s transformation
    α\alpha
    Significance level: the chance of a false positive
    1−β1-\beta
    Power: the chance of detecting the effect if it is real
    qq
    Expected dropout

    Formulas

    Difference of Fisher z values

    n=⌈2(z1−α/2+z1−βz(r1)−z(r2))2+3⌉n = \left\lceil 2\left(\frac{z_{1-\alpha/2} + z_{1-\beta}}{z(r_1) - z(r_2)}\right)^{2} + 3 \right\rceil

    Each group’s transformed correlation has variance 1/(n − 3), so their difference has twice that [1, 2].

    Dropout

    nrecruit=⌈n1−q⌉n_{\text{recruit}} = \left\lceil \frac{n}{1 - q} \right\rceil

    Applied last, to the participants actually recruited.

    Parameters

    Correlation in group 1rr

    Values: Between −1 and 1

    The smallest correlation worth detecting, from comparable studies. Weak correlations need large samples.

    Correlation in group 2r2r_2

    Values: Between −1 and 1, different from r₁

    Differences between correlations are hard to detect; expect large samples.

    Significance levelα\alpha

    Values: Between 0 and 1; usually 0.05

    The false-positive rate you accept. A smaller α, for example to allow for several primary outcomes, needs a larger sample.

    Power1−β1-\beta

    Values: Between 0 and 1; usually 0.80 or 0.90

    The chance of a significant result if the assumed effect is real. Funders and ethics committees commonly expect at least 0.80.

    Expected dropoutqqOptional

    Values: 0% up to, but not including, 100%

    The share of participants expected to provide no outcome, from comparable studies. Recruiting more restores the numbers, not the comparability of the groups: if dropout is related to the outcome, the estimate can still be biased.

    Assumptions

    • The groups are independent and equal in size; the measurements are roughly bivariate normal in each.
    • Dropout is unrelated to the outcome; recruiting more participants restores the numbers but cannot remove bias.

    Worked examples

    0.5 against 0.3

    r₁ = 0.5 and r₂ = 0.3: z(0.5) − z(0.3) = 0.240, so n = 2 × (2.8016 / 0.240)² + 3 = 276.0, rounded up to 277 per group.

    Group 1: 277 · Group 2: 277 · Total: 554

    Protocol statement

    To detect a difference between correlations of 0.5 and 0.3 with 80% power at a two-sided significance level of 0.05, using a comparison of two independent correlations, the required sample size is 277 per group (554 in total). Calculated with StatWisely (statwisely.com) using: n_per_group = 2[(z_(1-α/tails)+z_(1-β))/(atanh(r₁)-atanh(r₂))]²+3. These are planning estimates; confirm the final design with a qualified statistician.

    Open this example in the calculator

    Closer correlations

    r₁ = 0.4 against 0.3: 1209 per group.

    Group 1: 1209 · Group 2: 1209 · Total: 2418

    Open this example in the calculator

    Validation

    • Every worked example on this page is recomputed by the StatWisely engine whenever the software is built. If a number or formula here stopped matching the calculator, the release would be stopped until this document was corrected.
    • An independent implementation in R recomputes this test every night and before each production release, and the results are compared with the engine’s.

    How to cite

    StatWisely. Sample size to compare two independent correlations. Method document, engine version 1.0.0, reviewed 2026-10-01. https://statwisely.com/methods/correlation-compare/

    Cite the original references for the formulas your design uses as well.

    References

    1. 1.Fisher RA. On the “probable error” of a coefficient of correlation deduced from a small sample. Metron. 1921;1:3–32.
    2. 2.Cohen J. Statistical Power Analysis for the Behavioral Sciences. 2nd ed. Hillsdale, NJ: Lawrence Erlbaum Associates; 1988.