Bayes theorem
Brainteasers & GuesstimatesThe rule for flipping a conditional probability round, turning the chance of the evidence given the cause into the chance of the cause given the evidence.
Also written: Bayes rule, Bayesian updating
Bayes theorem answers the question an interviewer actually asks. You are usually handed the chance of seeing the evidence given the cause, a model catches 90% of defaults, and asked for the chance of the cause given the evidence, this borrower was flagged, so how worried should I be. The theorem is the conversion between the two, and the base rate is the exchange rate.
Do not write the formula out under pressure. Counting people is faster and much harder to get wrong: take a round population, split it by the base rate, apply the hit rate to one group and the false positive rate to the other, and read the answer off the two counts.
The odds form is the best second route, and it is quick enough to do while talking. Take the prior odds, multiply by the likelihood ratio, which is the hit rate divided by the false positive rate, and convert back to a probability. If it agrees with the counting method, you have checked your answer by a genuinely different path.
The result that surprises people is that a test can be accurate on both dimensions and still produce mostly false alarms. That is not a flaw in the test, it is arithmetic: rarity means the wrong population is much larger than the right one. Hedging on this question, rather than computing it, is what interviewers are watching for.
Worked example
A book of 10,000 borrowers, 4% default, a model catching 90% of defaults and flagging 8% of sound borrowers.
Counting: 360 correct flags against 768 false ones, so 360 of 1,128, about 31.9%.
Odds form as the check: prior odds 400 to 9,600, or 1 to 24. Likelihood ratio 90 over 8, which is 11.25. Posterior odds 11.25 to 24, so 11.25 over 35.25, which is 31.9% again. Two routes, one answer.