Part 1
Written summary
- Chapter 1: The Peeking Curse--–- The email arrived at 11:47 PM on a Friday.
- They were only at 32,000.
- This chapter reveals why peeking destroys the validity of classical A/B tests, why static experimentation fails in dynamic environments, and how a different framework—the multi-armed bandit—escapes these traps entirely.
Read along — the full text
Chapter 1: The Peeking Curse--–- The email arrived at 11:47 PM on a Friday. Sarah, a senior data scientist at a mid-sized travel booking platform, had been babysitting an A/B test for six weeks. The test compared two variants of the checkout button: green (control) versus gold (treatment). At week two, the gold button was winning by a statistically significant margin—a p-value of 0.03, well below the conventional 0.05 threshold. She showed the early results to her product manager, who immediately asked, "Can we roll this out before the holiday weekend?" Sarah hesitated. The test was designed for a fixed sample size of 100,000 users per variant.
They were only at 32,000. But the numbers looked so promising. The team was excited. The pressure was real. She decided to "just peek" and call it early.By week six, when the test finally reached its planned sample size, the gold button's lift had evaporated. Worse, it was now underperforming the green control by 0.7 percent—not statistically significant, but directionally negative. The product manager was confused. Sarah was embarrassed. The engineering lead was annoyed about the wasted implementation effort. And worst of all, the company had lost four weeks of potential revenue from the green button, revenue they could have captured if they had simply trusted the original design and launched nothing at all.Sarah had just experienced the peeking curse, a statistical trap so subtle and so pervasive that it has cost companies billions of dollars in foregone revenue, yet most data scientists learn about it only after getting burned.
This chapter reveals why peeking destroys the validity of classical A/B tests, why static experimentation fails in dynamic environments, and how a different framework—the multi-armed bandit—escapes these traps entirely. But, because this book is committed to intellectual honesty, we will also be explicit about what basic bandits cannot do, setting the stage for the advanced solutions in later chapters.The Three Failures of Static ExperimentationBefore we can appreciate the bandit solution, we must understand exactly how traditional A/B testing breaks in practice. The problems fall into three categories, each more insidious than the last, and each capable of invalidating months of careful work.Failure One: The Peeking IllusionStatistical hypothesis testing, as developed by Jerzy Neyman and Egon Pearson in the 1930s, assumes a fixed sample size.