Compare Two Fraud Models on the Same Transactions With McNemar's Test
Last updated: November 29, 2026
Quick Overview
Two fraud models score the same 2,000 labeled transactions. Model A is right on 1,820 and Model B on 1,780; A is right and B wrong on 120, B right and A wrong on 80. Is A significantly more accurate, and why is a two-proportion z-test the wrong tool?
Capital One
November 29, 20260
0
0 solved
Two fraud models score the same 2,000 labeled transactions. Model A is right on 1,820 and Model B on 1,780; A is right and B wrong on 120, B right and A wrong on 80. Is A significantly more accurate, and why is a two-proportion z-test the wrong tool?
Capital One model validation teams compare challenger and champion models on shared holdout data. The interviewer checks that you recognize paired data, apply McNemar's test, and question whether accuracy is the right metric for fraud.
What the Interviewer Expects
- Recognize that both models are evaluated on the same items, so outcomes are paired
- Build the 2x2 agreement table and focus on discordant pairs
- Compute McNemar's statistic (8.0, p about 0.005)
- Explain why the unpaired test misstates the variance
- Point out that accuracy is a poor metric under class imbalance
Key Topics to Cover
How to Approach This
- Define your hypotheses (H0 and H1) clearly before performing any test.
- Calculate required sample size BEFORE running an experiment, using power analysis.
- Remember the Central Limit Theorem: sample means become approximately normal with large n.
- Watch for Simpson's paradox. Always segment data by key dimensions.
- Distinguish between statistical significance and practical significance.
Possible Follow-up Questions
- What is the exact binomial version of this test?
- How would you compare the two models' AUCs on the same data?
- What if the discordant counts were 12 and 8?
- How would you compare models by dollar fraud loss instead of accuracy?
Sharpen Your Skills on Codemia
Practice similar problems with our interactive workspace, get AI feedback, and track your progress.
Browse Statistics QuestionsSample Answer
Clarify
2,000 transactions, both models scored each one. Agreement table:
| B correct | B wrong | |
| A correct | 1,700 | 120 |
| A wrong | 80 | 100 |
Accuracy A , B $=1780/20...
Approach
The 1,800 concordant transactions (both right or both wrong) carry no information about which model is better. Under , each of the discordant transactions is equally likely to favor eit...