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
Statistics & Math
Data Scientist
Capital One
November 29, 2026
Data Scientist
Onsite
Statistics & Math
Medium

0

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
McNemar's test
paired data
model comparison
discordant pairs
class imbalance
How to Approach This
  1. Define your hypotheses (H0 and H1) clearly before performing any test.
  2. Calculate required sample size BEFORE running an experiment, using power analysis.
  3. Remember the Central Limit Theorem: sample means become approximately normal with large n.
  4. Watch for Simpson's paradox. Always segment data by key dimensions.
  5. 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 Questions
Sample Answer
Clarify

2,000 transactions, both models scored each one. Agreement table:

B correctB wrong
A correct1,700120
A wrong80100

Accuracy A =1820/2000=91%=1820/2000=91\%, B $=1780/20...

Approach

The 1,800 concordant transactions (both right or both wrong) carry no information about which model is better. Under H0H_0, each of the b+c=200b+c=200 discordant transactions is equally likely to favor eit...


Submit Your Answer
Markdown supported