Where session 4 sits
Six sessions, 45 minutes each, no code. Sessions 1 to 3 built the estimate: what a prior costs, why eighteen observations give a distribution rather than a point, and how twelve outlets lend each other strength. Tonight the estimate has to carry a decision. Two posteriors, one for each voucher, sit on the table, and somebody has to say ship, wait, or stop. Session 5 is the argument about priors the field has not settled. Session 6 is what to require in writing so that everything you see tonight arrives in a form you can check. The example is still Halloway Bakeries, now at its flagship, Westfield, where 900 vouchers a month make an A/B test possible.
★ What you walk out with tonight. Three reads that work on any posterior anyone puts in front of you: where is the mass, how wide is it, and what does the width cost me if I act now. The measured case where a 0.915 probability was not enough, and the number that explained why: an expected loss of 0.0029 against a threshold of 0.001. And the honest price of the rule, computed rather than promised: across 200 replays, 23 would have stopped at n = 100 and 2 of those 200 would have stopped on the wrong arm.
LiveA posterior is a pile of plausible answers, and you can ask it questions4 min▶
Session 2 left you with the idea that an estimate from small data is a distribution: a spread of plausible values for the rate, heavier where the evidence points and thinner at the edges. Tonight the useful picture is more concrete. Think of the posterior as twenty thousand plausible values written on twenty thousand slips of paper. Each slip is one way the world could be, given what you believed and what you saw. Every question you could ask about the rate becomes a question about the slips.
With two vouchers there are two piles. Draw one slip from A's pile and one from B's and compare them. Do it twenty thousand times. The share of draws in which B's slip is higher is P(B > A), the probability that B is the better voucher. At Westfield after fifty customers per arm it was 0.915. The same draws answer a second question: in the draws where B is actually worse, how much worse is it, on average, counted across all the draws? That is the expected loss of choosing B, and at n = 50 it was 0.0029. The first number tells you how likely you are to be wrong. The second tells you what being wrong costs. Only one of them is a decision.
Halloway's product lead heard 0.915 and reached for the launch email. The analyst put the second number on the screen: choose B now, and on average you forfeit 0.0029 of redemption rate to the chance that B is the worse voucher. Halloway had agreed before the test that it would not act until that forfeit fell below 0.001. The email waited a week.
Self-studyThe words that will keep coming back4 min▶
- Posterior. The distribution of plausible values for a rate after the data. Tonight, twenty thousand draws from it, one pile per voucher.
- P(B > A). The share of paired draws in which B's rate beats A's. A probability, not a decision.
- Expected loss. How much redemption rate you forfeit on average if you pick this arm and it turns out to be the worse one. A probability times a stake, so it is a decision.
- Threshold. The expected loss below which Halloway agreed to act: 0.001. Chosen before the test, written down, and not moved during it.
- Stopping rule. Stop when the expected loss of the arm you would choose is below the threshold. It controls the cost of a wrong decision, not how often one happens.
- 89 percent interval. The range holding 89 percent of the posterior, cut equally from both tails, the 5.5 and 94.5 percent points. Every interval tonight is this kind and says so.
- Credible interval. The Bayesian interval. It is the sentence most people think a confidence interval is: there is an 89 percent probability the rate is in here. The frequentist sentence is different, and learn-statistics-with-phoebe owns it.
- ROPE. A region of practical equivalence: the band of differences too small to care about. Named by Kruschke (2013), and the device that lets a posterior say "no meaningful difference" out loud.
0.915 was not enough
10 min liveOne cumulative experiment at Westfield, voucher B against voucher A, flat priors, twenty thousand posterior draws. The true rates are written into the data: A 0.150, B 0.175, a lift of 2.5 points. The first fifty customers per arm came in at 0.100 and 0.200, a gap four times the true lift, and the room saw 0.915 and wanted to stop. The same two piles of slips, read for expected loss, said something else.
LiveWhy the rule said keep going at 0.9154 min▶
At n = 50 the two piles of slips overlap a great deal. In 91.5 percent of paired draws B's slip is higher, which sounds decisive, but look at the other 8.5 percent. In those draws A is the better voucher, and in some of them it is better by a lot, because fifty customers cannot pin either rate down. Average the shortfall across every draw, counting zero for the draws where B wins, and you get 0.0029: on average, choosing B now forfeits 0.0029 of redemption rate to the possibility that B is the worse arm. Halloway's threshold was 0.001. The rule said keep going, and the reason was not that 0.915 fell short of some magic cut-off. The reason was that being wrong was still expensive.
Fifty customers later, with the observed rates unchanged at 0.100 and 0.200, the piles have narrowed. P(B > A) rose to 0.975, a modest move. The expected loss of choosing B fell to 0.0005, a move by a factor of six, because the draws where A wins are now both rarer and closer. That is the general shape: the probability tells you how often you would be wrong, the expected loss tells you how much it would cost, and a threshold on the cost is what makes it a rule you can defend afterwards. The other side of the ledger is worth reading too. The expected loss of choosing A was 0.0984 at n = 50 and 0.0989 at n = 100. Nobody in the room was proposing A, but the number says why: staying with the current voucher was the expensive option all along.
Self-studyExpected loss, in words a finance director will accept3 min▶
The sentence is: "If we choose B and B is actually the worse voucher, we forfeit on average this much redemption rate." It is a probability multiplied by a stake, summed over every way the world could be, and that is exactly the shape of every other expected-cost number a finance team already uses. Nothing about it is novel except that the probabilities come from a posterior rather than a spreadsheet assumption.
Two properties make it the right number to put a threshold on. It falls as data arrive, because the losing draws get rarer and smaller together, so a threshold on it will eventually be met if a real difference exists. And it is in the units of the thing you care about, redemption rate, so the threshold can be set by asking what forfeit Halloway is willing to carry, rather than by asking what probability feels comfortable. Halloway said 0.001, a tenth of a point of redemption rate. A different business would say a different number, and that is the point: the threshold is a business decision made in advance, and the posterior only reports whether it has been reached.
LiveCredible against confidence, in one card2 min▶
Every interval tonight is an 89 percent equal-tailed credible interval: the 5.5 and 94.5 percent points of the posterior. It supports the sentence "there is an 89 percent probability the rate is in this range", which is the sentence almost everybody hears when a confidence interval is read out in a meeting. The frequentist confidence interval supports a different sentence, about the procedure rather than the rate, and learn-statistics-with-phoebe session b7 owns that sentence. It is not re-derived here. What matters for reading a posterior is only this: when a Bayesian analyst says 89 percent, they mean it about the rate in front of you, and you are allowed to use it that way.
The rule is not free. It is cheap.
7 min liveA stopping rule that is applied as the data arrive will sometimes stop on the wrong arm. That is true of this one too, and the honest thing is to count how often rather than to claim it does not happen. The Westfield experiment was replayed two hundred times from different seeds, and the rule was applied at n = 100 in each. The count is below, alongside the path the real experiment took.
LiveTwo in two hundred, and the claim not to make3 min▶
Replay the Westfield experiment two hundred times with the same true rates and different customers, apply the rule at n = 100 each time, and 23 of the 200 would have stopped there. Of those 200 replays, 2 would have stopped on the wrong arm. State it as a count, because that is what it is. The rule kept the cost of each wrong stop small, and it did not make wrong stops impossible. Nothing does.
Which is why there is a sentence you should never hear from an analyst and never repeat: that Bayesian A/B testing "has no peeking problem" or "lets you stop whenever you like". The expected-loss rule controls the cost of a wrong decision. It does not control the frequency of one, and the 2 in 200 above is the frequency. Whether a stopping procedure applied as data arrive inflates that frequency, and by how much, is a real argument, and learn-experimentation-with-phoebe session b6 owns it. Tonight's job is only to report the measured rate and to make sure nobody in the room mistakes a cheap rule for a free one.
Halloway's board pack said "the new voucher wins, probability 0.975". The analyst added one line: "under this rule, replayed two hundred times, we would expect to ship the wrong voucher about twice, and the forfeit each time would be under a tenth of a point." The line was the difference between a number and a decision the board could own.
Self-studyKruschke and the region of practical equivalence3 min▶
P(B > A) can only ever say which arm is ahead. It cannot say "these two are the same for any purpose that matters", because with enough data one arm is always ahead by a hair. Kruschke (2013), "Bayesian estimation supersedes the t test", Journal of Experimental Psychology: General, 142(2), 573-603, supplies the missing move. Decide in advance the band of differences too small to care about, the region of practical equivalence, and compare the posterior interval for the difference to it. If the interval falls entirely inside the band, you can accept "no meaningful difference" as a positive finding, something a test cannot do. If it falls entirely outside, the difference is real and large enough to act on. If it straddles, you do not know yet.
For a leader the useful part is the first case. A precise estimate that lands inside the ROPE is a licence to stop spending on a question, and it is the one outcome that a probability-of-difference alone can never deliver. Ask for the band before the data arrive, in the units of the decision: at Halloway, "a difference under half a point of redemption rate does not change what we do" would have been enough.
LiveThe three reads of any posterior2 min▶
Whatever is on the screen, three questions read it. Where is the mass? The bulk of the plausible values, the region the posterior mean and the middle of the interval both point at. How wide is it? The 89 percent equal-tailed interval, and whether its two ends would lead you to different actions. What does the width cost me if I act now? The expected loss of the action you are about to take, which is the width translated into the stake. The first two are about the estimate. The third is the decision, and it is the one the meeting is actually there to make.
Read a posterior cold
20 min build-alongNo laptop. Take a comparison your area is going to make on a probability: a new design against the current one, a supplier against the incumbent, a message against the control. Whether or not anyone has computed a posterior yet, the build-along walks the six questions you will ask when they do, in the order that turns a probability into a decision you can defend afterwards.
Name the two arms and the stake. "Voucher B against voucher A, and the stake is redemption rate." If the stake is not in units anyone budgets in, translate it until it is. Expected loss is only useful in units you would notice losing.
Set the threshold before you see anything. How much of the stake are you willing to forfeit, on average, to a wrong choice? Halloway said 0.001 of redemption rate. Write yours down and date it. A threshold set after the numbers arrive is not a rule, it is a rationalisation.
Ask where the mass is. For each arm, the posterior mean and the 89 percent equal-tailed interval. Say the two sentences: "A is probably near 0.100, B near 0.200." Then the harder one: "and the two intervals overlap, which means the ordering is not settled."
Ask for P(B > A) and refuse to stop there. Hear the number, 0.915 or whatever it is, and say out loud: "that is how often I would be wrong, not what it costs." The room will want to act on it. The whole build-along exists for this moment.
Ask for the expected loss of the arm you would choose. "If I choose B and B is worse, what do I forfeit on average?" Compare it to the threshold from step 2. Above: keep going. Below: act. At Westfield it was 0.0029 against 0.001 at n = 50, and 0.0005 at n = 100.
Write the sentence that goes in the pack. "We choose [arm]. The probability it is the better one is [P]. If it is not, we forfeit on average [expected loss] of [stake], against a threshold of [threshold] set on [date]. Replayed under this rule, we would expect to choose wrongly about [count] times in [replays]." Every bracket is a number you can be held to.
The question that changes the meeting. "If we are wrong, what does it cost us on average?" It moves the conversation from a probability, which people argue about by feel, to a forfeit in the units of the business, which people argue about with a budget. And it exposes at once whether anyone set a threshold before the data came in.
Three questions
At n = 50 per arm the posterior gave P(B > A) = 0.915 and the rule said keep going. Why?
The rule is on the expected loss, not on the probability. In the 8.5 percent of draws where A was better, it was often better by a lot at n = 50, so the average forfeit from choosing B was still 0.0029. There is no probability cut-off in the rule at all; fifty customers later the loss was 0.0005 and the same rule said stop.
Across 200 seeded replays of the Westfield experiment, stopping at n = 100 by the same rule, 23 would have stopped and 2 would have stopped on the wrong arm. What does that number tell you about the rule?
The expected-loss rule keeps each wrong stop cheap. It does not make them impossible, and the honest thing is to report the count. Whether a rule applied as data arrive inflates that count is the peeking argument, and learn-experimentation-with-phoebe b6 owns it. No threshold drives the count to zero on finite data.
An analyst reports an 89 percent credible interval for an outlet's redemption rate, from 0.124 to 0.161. What are you allowed to say in the meeting?
The credible interval is the sentence everybody thinks a confidence interval is, and for a credible interval it is true. The sentence in B belongs to the frequentist confidence interval, which learn-statistics-with-phoebe b7 owns and this session does not re-derive. Every interval here is 89 percent equal-tailed because that is the tooling's default; nothing needs converting.
Before session 5
30 minFind one decision your area made in the last year on a probability alone: "80 percent likely to work", "very likely to convert", "probably the better supplier". Write down what the stake was, in units somebody budgets, and what a wrong choice would have forfeited on average. Then write down what threshold you would have set, in those units, before seeing anything. Bring the three numbers. Session 5 turns to the other end of the analysis, the prior, and the argument about how to choose one that the field has not settled. It helps to arrive knowing what your own decisions are actually worth.