# Base Rates and Expected Value: Why 99% Accurate Isn't Enough by [kirupa](https://www.kirupa.com/me/index.htm) | filed under [Data & Decisions](https://www.kirupa.com/data_and_decisions/index.htm) **TL;DR:** A base rate is how common something is before we test for it. When the thing a detector hunts for is rare, even a 99% accurate detector raises more false alarms than real ones. Count the alarms on 1,000 items, then weigh what each kind of mistake costs before deciding what an alarm should do. - With 1 stolen card in 1,000 orders, a filter that catches 99% of them and flags 1% of good orders raises 11 alarms, and only 1 is real. - In a 1978 Harvard Medical School survey, 27 of 60 people said a positive result meant a 95% chance of disease. The right answer was about 2%. - A detector that always says not fraud is 99.9% accurate and catches nothing, so ask for the catch rate and the false alarm rate instead. - Expected value adds up what each outcome costs times how often it happens. At 1 in 1,000, auto-cancelling flagged orders costs about $649 a month, versus $55 for doing nothing. A payments vendor emailed Wren last month with a pitch: an AI fraud filter for Crumb & Co.'s online orders, **99%** accurate, for $49 a month. Wren turned it on and let it cancel anything it flagged. In its first week, it cancelled three orders. All three came from real customers, including a regular who has picked up the same rye loaf every Friday for years. How can something that's 99% accurate be wrong three times out of three? Nothing was broken, and the vendor was not lying. In this article, we'll see why a very accurate detector can still be wrong most of the time it raises an alarm, and how to decide whether an alarm is worth having at all. Onwards! ## The 99% Accurate Fraud Filter Here is the vendor's email: [![An email to Wren from a payments vendor with the subject Our AI fraud filter is 99% accurate. The body says: It catches 99% of stolen cards. It flags only 1% of good orders. Turn on auto-cancel and stop fraud for $49 a month.](https://www.kirupa.com/data_and_decisions/images/base_rates_and_expected_value_pitch.png)](https://www.kirupa.com/data_and_decisions/images/base_rates_and_expected_value_pitch.png?v=4e6738c53c1a) The pitch gives us two numbers. The filter catches 99% of orders placed with a stolen card, and it flags 1% of good orders by mistake. Both numbers sound great. Neither one tells us what we actually want to know when the filter cancels an order, which is how likely it is that this particular order is fraud. Here are the three orders it cancelled in its first week: [![The three orders the filter cancelled in its first week. Order 4102, a rye loaf, from a regular who orders every Friday. Order 4117, a birthday cake. Order 4131, a dozen croissants for an office. All three were real customers with their own cards, and none of the week's orders used a stolen card.](https://www.kirupa.com/data_and_decisions/images/base_rates_and_expected_value_first_week.png)](https://www.kirupa.com/data_and_decisions/images/base_rates_and_expected_value_first_week.png?v=b5173c48213a) Every one of them was a real customer paying with their own card, and Biscuit had to apologize to all three. To see what happened, we are going to do something very low-tech. We are going to count. ## A Month of Orders as 1,000 Dots Crumb & Co. gets about 1,000 online orders a month. When Wren looked back at last year's chargebacks, about 1 order in 1,000 had been placed with a stolen card. Let's draw one month of orders as 1,000 dots: [![A grid of 1,000 dots, one for each online order Crumb & Co. gets in a month. 999 are gray, real customers paying with their own cards. One dot is red: the single order placed with a stolen card.](https://www.kirupa.com/data_and_decisions/images/base_rates_and_expected_value_grid_month.png)](https://www.kirupa.com/data_and_decisions/images/base_rates_and_expected_value_grid_month.png?v=1054c1993238) Out of our 1,000 dots, 999 are real customers and 1 is a stolen card. Now we will run the filter over them. It will catch our 1 stolen card, since 99% of 1 is about 1. It will also flag 1% of our 999 good orders, which is about 10 of them: [![The same 1,000 dots after the filter runs. The red stolen-card order is circled because the filter caught it. Ten gray dots now have an orange outline: real customers the filter flagged by mistake. That makes 11 alarms in all.](https://www.kirupa.com/data_and_decisions/images/base_rates_and_expected_value_grid_flagged.png)](https://www.kirupa.com/data_and_decisions/images/base_rates_and_expected_value_grid_flagged.png?v=426b50b33e2c) Our filter raised 11 alarms in all. Here they are lined up next to each other: [![The 11 orders the filter flagged, pulled out of the grid and lined up. One is the stolen-card order. The other ten are real customers. Only 1 of the 11 alarms is real, which is about 9%.](https://www.kirupa.com/data_and_decisions/images/base_rates_and_expected_value_grid_sorted.png)](https://www.kirupa.com/data_and_decisions/images/base_rates_and_expected_value_grid_sorted.png?v=e1eab9f04d50) Only **1** of our 11 alarms is a stolen card, which is about **9%**. This means that when our filter raises an alarm, it is wrong about 91% of the time, even though it is 99% accurate. Is the filter broken? Nope. It is doing exactly what the vendor promised. What sinks us is how rare stolen cards are to begin with. In a month, there is only 1 stolen card for the filter to find and 999 good orders for it to make mistakes on, so even a 1% mistake rate turns into 10 false alarms. How common something is before we test for it has a name, and it is called the **base rate**. Forgetting about it is so common that it has a name too: **base-rate neglect**. If you read our [Recall vs. Precision](https://www.kirupa.com/ai_fundamentals/recall_vs_precision.htm) article, these numbers will look familiar. The 99% catch rate is the filter's **recall**, and the share of alarms that are real (our 9%) is its **precision**. That article fished for 4 trout in a lake. Our lake has 1 trout and 999 old boots. ## Doctors Fall for This Too If this feels slippery, you're in good company. In 1978, Ward Casscells, Arno Schoenberger, and Thomas Graboys [asked 60 people](https://doi.org/10.1056/NEJM197811022991808) at Harvard Medical School teaching hospitals one question. A disease affects 1 in 1,000 people, and a test for it has a 5% false positive rate. If someone tests positive, what is the chance they actually have the disease? Here is how they answered: [![Answers from Casscells, Schoenberger, and Graboys (1978). 60 house officers, fourth-year medical students, and attending physicians were asked how likely disease is after a positive result, when the disease affects 1 in 1,000 people and the test has a 5% false positive rate. 27 of the 60 answered 95%. Only 11 gave the right answer, about 2%. The other 22 gave other answers.](https://www.kirupa.com/data_and_decisions/images/base_rates_and_expected_value_casscells.png)](https://www.kirupa.com/data_and_decisions/images/base_rates_and_expected_value_casscells.png?v=9427bcc7b793) The most common answer was 95%, from 27 of the 60. Only 11 got the right answer, which is about 2%. What helps here is the same trick we used with our dots. We count people instead of juggling percentages: [![The doctors' question counted out with people instead of percentages. Out of 1,000 people, 1 has the disease and 999 don't. The 1 sick person tests positive. About 5% of the 999 healthy people, 50, test positive too. So 1 of the 51 positives is sick, about 2%.](https://www.kirupa.com/data_and_decisions/images/base_rates_and_expected_value_counts.png)](https://www.kirupa.com/data_and_decisions/images/base_rates_and_expected_value_counts.png?v=e3d39f3c0ddf) Out of 1,000 people, the 1 sick person tests positive. About 50 of the 999 healthy people test positive too. So only 1 of the 51 positives is sick, which is about 2%. Gerd Gigerenzer and Ulrich Hoffrage [tested this trick in 1995](https://doi.org/10.1037/0033-295X.102.4.684). When they gave people counts instead of percentages, the share of answers that followed the right reasoning jumped from 16% to 46%. ## The Rarer the Thing, the Worse the Alarms Let's keep our filter exactly the same and change how rare stolen cards are: [![The share of alarms that are real for the same filter, which catches 99% of stolen cards and flags 1% of good orders, as stolen cards get rarer. At 1 in 10 orders, 92% of alarms are real, 1 in 100: 50%, 1 in 1,000: 9%, 1 in 10,000: 1%.](https://www.kirupa.com/data_and_decisions/images/base_rates_and_expected_value_rarer.png)](https://www.kirupa.com/data_and_decisions/images/base_rates_and_expected_value_rarer.png?v=b04d00c76a30) When 1 order in 10 is fraud, 92% of our alarms are real. At 1 in 100, it is a coin flip. At 1 in 1,000, which is us, only 9% are. Nothing about our filter changed between these rows. The only thing that changed is the base rate. This is also why accuracy is a misleading number when the thing we're looking for is rare. Here is our vendor's filter next to a lazy detector that says "not fraud" to every single order: [![Two detectors on a month of 1,000 orders with 1 stolen card. The vendor's filter is right about 99.0% of the time and catches the stolen card. A detector that says not fraud to every order is right 99.9% of the time and catches nothing. The lazy one has the higher accuracy.](https://www.kirupa.com/data_and_decisions/images/base_rates_and_expected_value_accuracy_trap.png)](https://www.kirupa.com/data_and_decisions/images/base_rates_and_expected_value_accuracy_trap.png?v=a4db4085e9f9) The lazy detector is right 999 times out of 1,000, so it scores **99.9%** accurate, which beats our vendor. It also never catches anything! When fraud is this rare, accuracy mostly tells us how rare fraud is. The numbers worth asking a vendor for are the catch rate and the false alarm rate, and the one number only we can supply is our own base rate. ## Try the Base-Rate Dot Grid Here are our 1,000 orders again, and this time you control the dials: Interactive example: [Base-Rate Dot Grid](https://www.kirupa.com/data_and_decisions/examples/base_rate_dot_grid.htm) **Try it:** 1. Check **Line up the alarms** 2. Pick **1 in 100**, then **1 in 10** 3. Back at **1 in 1,000**, pick **0.1%** Making fraud more common pushes the share of real alarms up fast. At our 1 in 1,000, it takes a filter that flags only 0.1% of good orders to get about half of its alarms right, which is a much harder filter to build. The cost chips at the bottom are where we are going next. ## What's an Alarm Worth? Knowing that 9% of our alarms are real does not tell us what to do yet. For that, we need to know what each kind of mistake costs. Wren and the owner sat down with the numbers. A stolen-card order that slips through costs about **$55**: the $40 order plus a $15 chargeback fee. Cancelling a real customer's order costs about **$60**: the $40 sale plus about $20 for the chance that customer gets annoyed and stops ordering. (That last number is a guess, and that's okay. A rough guess beats pretending it's zero.) Rosa, our shift lead, offered a third option. Instead of cancelling a flagged order, she could text or call the customer to confirm it, which takes a couple of minutes, or about $2 of her time. Here is what each kind of alarm costs us under each plan: [![The filter raises about 11 alarms a month. If we auto-cancel them, the 1 real one saves us $55, the cost of a stolen-card order, and each of the 10 false ones costs $60, a lost sale plus a customer who might not come back. If Rosa checks each alarm instead, every alarm costs about $2 of her time, and she still stops the stolen card.](https://www.kirupa.com/data_and_decisions/images/base_rates_and_expected_value_ev_tree.png)](https://www.kirupa.com/data_and_decisions/images/base_rates_and_expected_value_ev_tree.png?v=ea2740516e24) Now we will do one more round of counting. For each plan, we multiply what each outcome costs by how often it happens in a month, and we add it all up, including the filter's $49 fee. That total has a name, and it is called the **expected value** (in our case, the expected cost). Here it is for our three choices: [![The expected cost per month of each choice when 1 order in 1,000 uses a stolen card, counting the filter's $49 fee. Doing nothing costs about $55. Auto-cancelling alarms costs about $649. Having Rosa check each alarm costs about $72. Doing nothing is cheapest.](https://www.kirupa.com/data_and_decisions/images/base_rates_and_expected_value_ev_bars.png)](https://www.kirupa.com/data_and_decisions/images/base_rates_and_expected_value_ev_bars.png?v=8c5dae7beb5b) Auto-cancel costs us about **$649** a month, and almost all of it comes from cancelling 10 real customers. Having Rosa check every alarm costs about $72. Doing nothing costs about $55, because one stolen card a month just is not that expensive. So, the honest answer for Crumb & Co. right now is to skip the filter. It's a good filter, and our fraud problem is too small to be worth $49 a month. That answer depends on our base rate, though. Let's say someone starts testing stolen cards on our checkout, and fraud jumps to 1 order in 100: [![The same three choices when 1 order in 100 uses a stolen card. Doing nothing now costs about $550 a month. Auto-cancelling alarms costs about $648. Having Rosa check each alarm costs about $94, which is now the cheapest by far.](https://www.kirupa.com/data_and_decisions/images/base_rates_and_expected_value_ev_flip.png)](https://www.kirupa.com/data_and_decisions/images/base_rates_and_expected_value_ev_flip.png?v=0d5d3dec3f3d) Now doing nothing costs about $550 a month, and Rosa's quick check costs about $94. The filter is suddenly a great deal, as long as we pair it with Rosa's check instead of auto-cancel. The filter didn't change at all. The base rate did, and it flipped which choice has the best expected value. ## Alarms in Our Own Products This is not just a fraud problem. A lot of the AI features we build are detectors, and most of what they look for is rare. Here are three alerts Wren might build for Biscuit: [![Three alerts Wren might build for Biscuit: a judge that flags replies where Biscuit made something up, a prompt injection detector, and a flag for angry customers. For each, how common the thing is, how often the alert catches it, and how often it false-alarms. Made-it-up judge: 2.00% of messages, catches 90%, false alarms on 5%, so 27% of its alarms are real. Prompt injection detector: 0.02% of messages, catches 99%, false alarms on 1%, so 2% of its alarms are real. Angry customer flag: 5.00% of messages, catches 80%, false alarms on 10%, so 30% of its alarms are real.](https://www.kirupa.com/data_and_decisions/images/base_rates_and_expected_value_own_alerts.png)](https://www.kirupa.com/data_and_decisions/images/base_rates_and_expected_value_own_alerts.png?v=706efc6bf158) A judge that flags replies where Biscuit made something up sounds great with a 90% catch rate, and yet only 27% of its alarms will be real. A prompt injection detector that is 99% accurate, watching for attacks that show up in 1 of every 5,000 messages, will be wrong about 98% of the time it fires. None of this means we should skip these alerts. It means we should decide up front what happens when one fires, and send its alarms somewhere cheap to check (like a review queue) instead of somewhere expensive (like a customer's cancelled order). There is a very old story about what happens when most alarms are false: [![Eleven speech bubbles that all say Wolf! Ten of them have nothing behind them. Only the last one has a real wolf next to it, and by then the villagers have stopped looking up.](https://www.kirupa.com/data_and_decisions/images/base_rates_and_expected_value_wolf.png)](https://www.kirupa.com/data_and_decisions/images/base_rates_and_expected_value_wolf.png?v=3d42808d1368) In Aesop's fable, the boy cries wolf so many times that nobody comes when the wolf finally shows up. Hospitals know this one well. A [2013 review](https://doi.org/10.1097/NCI.0b013e3182a903f9) by Sue Sendelbach and Marjorie Funk found that 72% to 99% of clinical alarms are false, and that the flood of them leads to alarm fatigue, where people stop responding. If most of our alarms are false, the people watching them will learn to ignore them, real ones included. ## Try It This Week Pick one alert, flag, or detector in your product (an error alert, a moderation filter, or an LLM judge), and let's find out how often its alarms are real: 1. Write down the base rate: out of 1,000 items, how many are the real thing? 2. Write down how many of those it catches, and how many of the rest it flags by mistake. 3. Divide the real alarms by all of the alarms. That's the share of its alarms you can trust. 4. Put a rough price on a miss, a false alarm, and a check, and add up the expected cost of each thing you could do when it fires. ## Frequently Asked Questions **What Is Base Rate Neglect?** It’s forgetting how common something is before we test for it. A detector that’s 99% accurate sounds trustworthy, but if only 1 order in 1,000 is fraud, almost everything it looks at is innocent, so even a 1% mistake rate makes 10 false alarms for every real one. In a 1978 survey at Harvard Medical School, 27 of 60 people made this mistake on a medical test question. **Why Can a 99% Accurate Test Still Be Wrong Most of the Time?** Accuracy counts how often a test is right across everything it checks, and most of what it checks is the common case. With 1 stolen card in 1,000 orders, a filter that catches 99% of stolen cards and flags 1% of good orders raises 11 alarms, and only 1 of them is real. So it’s wrong about 91% of the time it raises an alarm. **What Is the Difference Between Accuracy and Precision?** Accuracy is the share of all items a detector gets right. Precision is the share of its alarms that are real. When the thing we’re looking for is rare, they can be wildly different: a detector that always says not fraud is 99.9% accurate and has no useful alarms at all. **How Do You Use Expected Value to Make a Decision?** For each choice, multiply what each outcome costs by how often it happens, then add them up. For our fraud filter at 1 stolen card in 1,000 orders, auto-cancelling flagged orders costs about $649 a month, having someone check each alarm costs about $72, and doing nothing costs about $55. The cheapest choice changes when the base rate changes. ## Conclusion Ok! It is time to wrap things up. A detector's accuracy tells us how often it is right across everything it looks at. When the thing it's looking for is rare, almost everything it looks at is innocent, so even a tiny mistake rate produces more false alarms than real ones. That is how our 99% accurate filter ended up right only 1 time in 11. The base rate belongs in every conversation about an alarm, and expected value is how we turn alarm counts into a decision. As for Wren, the filter is off for now, with a reminder to rerun the math every quarter. The rye loaf regular got a free croissant with their next Friday order...and nobody cancelled it. Before you go, here are a few things you can do: 1. Read the next article in the series, [Survivorship Bias](https://www.kirupa.com/data_and_decisions/survivorship_bias.htm), or check out some related content: - [Recall vs. Precision](https://www.kirupa.com/ai_fundamentals/recall_vs_precision.htm). What recall and precision measure, explained with a net and a lake. - [Automation Bias and Vigilance: Why People Stop Checking AI](https://www.kirupa.com/human_behavior/automation_bias.htm). Why rare mistakes get missed by the people reviewing an AI. - [Calibrated Trust: Showing AI Uncertainty People Can Use](https://www.kirupa.com/human_behavior/calibrated_trust.htm). Show uncertainty that tells people what to check next. 2. Stuck on something, or curious about a detail we skipped? [Ask on the forums](https://forum.kirupa.com/), and we’ll help you out. ## Test your knowledge! [Take the Reviewing Base Rates and Expected Value Quiz](https://www.kirupa.com/quizzes/base_rates_and_expected_value.htm). Practice with 5 multiple-choice questions and an explanation after every answer.