Calculator
Enter the 2×2 paired contingency table. Rows = first measurement (Before / Test 1); Columns = second measurement (After / Test 2).
StatClinicClinical Statistics SuiteTest for a significant net change in paired binary outcomes — pre/post treatment response, or compare two paired diagnostic tests performed on the same patients.
Enter the 2×2 paired contingency table. Rows = first measurement (Before / Test 1); Columns = second measurement (After / Test 2).
The McNemar test evaluates whether there is a statistically significant difference in proportions of a binary outcome between two paired measurements. Unlike the chi-square test, it is designed for paired data — the same subjects measured at two time points (e.g., before and after treatment), or matched diagnostic tests on the same patients.
Only the discordant pairs (cells b and c) contribute statistical information. Subjects who remained the same across both measurements (concordant pairs a and d) do not affect the test result. The formula is:
χ² = (b − c)² / (b + c) [without continuity correction]
χ² = (|b − c| − 1)² / (b + c) [with Edwards correction, recommended when b+c < 25]
Reporting format (APA/journal): McNemar χ²(1, N=100) = 16.03, p < 0.001
Use McNemar when you have paired binary (yes/no) data from the same subjects measured twice — for example, treatment response before and after an intervention, or two diagnostic tests on the same patients. The key requirement is that observations are paired, not independent.
Chi-square tests association between two independent categorical variables. McNemar tests whether the proportion of a binary outcome differs in paired data. Using a standard chi-square test on paired data ignores the within-subject correlation and inflates the Type I error rate.
Discordant pairs are subjects who changed outcome: positive before but negative after (cell b), or negative before but positive after (cell c). Only these pairs drive the McNemar test. Concordant subjects — those who stayed the same (a or d) — do not affect the result.
Report: McNemar χ²(1, N=total) = value, p = value. State the before and after proportions and the direction of change. Example: "Before the intervention, 40% of patients had uncontrolled hypertension; after the intervention, 18% did. The net reduction was statistically significant: McNemar χ²(1, N=100) = 14.67, p < 0.001."
Apply the Edwards continuity correction (|b−c|−1)² / (b+c) when the total discordant pairs (b+c) is less than 25. For larger samples, the correction makes little difference and the uncorrected version is also acceptable.