---
title: "McNemar test (paired binary)"
method_id: SM.DIF.CAT.2DEP.MCNEMAR
family: Difference
version: 1.1.0
date_modified: 2026-06-18
canonical: https://clarus.ofrencber.com/library/mcnemar_test.md
source: Clarus method library
---

# McNemar test (paired binary)

> A classical statistical method in the Clarus library (Difference family).
> Clarus selects, assumption-checks and runs this method on your data with a
> deterministic rule engine and real numerical libraries (scipy / statsmodels);
> it never generates numbers, citations or results.

**Also known as:** McNemar's chi-square test; paired chi-square test; test of paired proportions; before-after dichotomous test.

## Hypotheses

- **Null (H0):** P(0->1) = P(1->0) (marginal proportions equal: P({dependent}=1 | {condition1}) = P({dependent}=1 | {condition2}))
- **Alternative (H1):** P(0->1) != P(1->0) (marginal proportions differ)

## When to use it

Use this method when your goal is to:
- compare two related proportions
- test paired binary change
- before after dichotomous response

## Data it expects

- **dependent:** 1 binary/dichotomous outcome measured twice on the same units (e.g. pass/fail, present/absent, yes/no)
- **independent:** 1 within-subjects factor / 2 related conditions (e.g. before vs after)
- **pairing:** paired (repeated or matched)

## Assumptions Clarus checks

- **paired independence** (severity: critical; on violation: warn_only)
- **binary paired outcome** (severity: critical; on violation: warn_only)
- **sufficient discordant for asymptotic** (severity: warning; on violation: correct)

## Effect size reported

- **odds ratio** (Paired (McNemar) odds ratio = b / c, the ratio of the two discordant transition counts (0->1 vs 1->0); 1.0 indicates no directional asymmetry.)

## Honest limitations

- McNemar uses ONLY the pairs that changed outcome (discordant pairs); concordant pairs (no change) do not affect the result, so a large sample with few changers can still yield a coarse, low-power test.
- The outcome must be strictly binary and the two measurements must be on the SAME (or matched) units; for two independent groups use a 2x2 chi-square instead.
- When few pairs change, use the exact binomial form; the asymptotic chi-square approximation can be misleading.
- A significant result indicates an asymmetric shift between occasions; it is not causal unless the two conditions arose from random assignment.
- For a paired outcome with more than two categories, McNemar does not apply (use the McNemar-Bowker test).

## Primary sources

- McNemar, Q. (1947). Note on the sampling error of the difference between correlated proportions or percentages. Psychometrika, 12(2), 153-157. https://doi.org/10.1007/BF02295996
- Edwards, A. L. (1948). Note on the 'correction for continuity' in testing the significance of the difference between correlated proportions. Psychometrika, 13(3), 185-187. https://doi.org/10.1007/BF02289261
- Agresti, A. (2013). Categorical Data Analysis (3rd ed.), Ch.11. Wiley.
- Fleiss, J. L., Levin, B., & Paik, M. C. (2003). Statistical Methods for Rates and Proportions (3rd ed.). Wiley.

## How to cite this

To cite this Clarus method page (the page itself — for the method's own primary sources, see above):

**Plain text**

Clarus, "McNemar test (paired binary)", version 1.1.0, Clarus method library, 2026. https://clarus.ofrencber.com/library/mcnemar_test.md

**APA**

Clarus. (2026). McNemar test (paired binary) (Version 1.1.0) [Statistical method, Clarus method library]. Retrieved from https://clarus.ofrencber.com/library/mcnemar_test.md

**BibTeX**

```bibtex
@misc{clarus-mcnemar-test,
  author       = {Clarus},
  title        = {McNemar test (paired binary)},
  howpublished = {Clarus method library},
  version      = {1.1.0},
  year         = {2026},
  url          = {https://clarus.ofrencber.com/library/mcnemar_test.md}
}
```

_No DOI is minted for Clarus method pages yet; this citation uses the canonical URL, version and date. Cite the primary sources above for the method's scientific provenance._

---

METHOD SM.DIF.CAT.2DEP.MCNEMAR · VERSION 1.1.0 · UPDATED 2026-06-18 · SOURCE Clarus method library
