Effect size measure

Phi Coefficient Calculator

The phi coefficient (φ)measures the strength of association between two binary variables in a 2×2 contingency table. It ranges from −1 to +1 (or 0 to 1 in magnitude), where 0 means no association and ±1 means a perfect one — and for a 2×2 table it is mathematically identical to Cramér's V.

Reviewed by the crosstabs.com methods team · Last updated

Run this on your own data — free, no signup

Upload a CSV or XLSX. Everything runs in your browser; your file never leaves your device.

Open the workspace →

What is the phi coefficient?

Phi is the categorical analogue of a correlation coefficient for two yes/no variables. Coded as 0 and 1, the phi coefficient is exactly the Pearson correlation between those two binary columns, which is why it carries a sign: positive φ means the two “1” categories occur together more than chance, negative φ means they avoid each other.

Because it is built from the chi-square statistic, phi pairs naturally with a chi-square test: the test tells you whether two variables are associated, and phi tells you how strongly.

Formula

Definition

φ = (ad − bc) / √((a+b)(c+d)(a+c)(b+d))

a, b, c, d
= the four cell counts of a 2×2 table [[a, b], [c, d]]
equivalently
= |φ| = √(χ² / n), where n is the grand total

Worked example

Worked example

Suppose 110 people are cross-tabulated by whether they saw an ad (rows) and whether they bought (columns):

[[30, 10], [10, 60]] → a=30, b=10, c=10, d=60

Numerator: ad − bc = (30×60) − (10×10) = 1800 − 100 = 1700.
Denominator: √((40)(70)(40)(70)) = √7,840,000 = 2800.
φ = 1700 / 2800 = 0.61.

A phi of 0.61 is a strong positive association — seeing the ad and buying go together far more than chance.

When to use it

Use it when

  • Both variables are binary (exactly two categories each).
  • You have a 2×2 contingency table and want an effect size to accompany a chi-square test.
  • You want a signed measure that shows direction, not just strength.

Not the right tool when

  • The table is larger than 2×2 — use Cramér's V instead.
  • Either variable is continuous — use the Pearson correlation.
  • You only care about an exact p-value for a tiny sample — use Fisher's exact test for that, then report phi.

How to interpret it

Rule of thumb

As a rough guide (Cohen), |φ| ≈ 0.1 is a small effect, ≈ 0.3 is medium, and ≈ 0.5 or above is large. The sign indicates direction; the magnitude indicates strength.

Frequently asked questions

Is the phi coefficient the same as Cramér's V?
For a 2×2 table, yes — phi and Cramér's V are mathematically identical. For tables larger than 2×2 they differ, and Cramér's V is the right choice because it stays bounded between 0 and 1.
Can the phi coefficient be negative?
Yes. Computed as (ad − bc) over the square-root term, phi ranges from −1 to +1 and carries a sign that shows the direction of association. The magnitude √(χ²/n) is always between 0 and 1.
What is a good phi coefficient value?
There is no universal threshold, but Cohen's benchmarks are common: about 0.1 is small, 0.3 is medium, and 0.5 or more is large. Always interpret it alongside the chi-square p-value and your context.
How is phi related to the Pearson correlation?
If you code each binary variable as 0 and 1, the phi coefficient is exactly the Pearson correlation coefficient between the two columns.

References & further reading

Try it on your own data — free, no signup

Upload a CSV or XLSX. Everything runs in your browser; your file never leaves your device.

Open the workspace →

Related calculators

← All calculators & guides