Bayesian vs. Frequentist A/B Test Reading Guide: Probability That B Beats A and What a P-Value Does Not Say
Read a conversion experiment using a named frequentist test and explicit Bayesian priors, then separate evidence of any lift from economically worthwhile lift.
The short answer
A p-value summarizes incompatibility with a specified null model; it is not the probability that B beats A. A Bayesian probability of improvement is conditional on the likelihood and prior. Report effect size and uncertainty with either approach, and distinguish any positive lift from a gain large enough to justify switching costs and operational risks.
Key takeaways
- Name the test and the uncertainty procedure.
- A p-value is not a posterior probability.
- State the prior and practical improvement threshold.
- Validate monitoring and decision rules, not only a final percentage.
Direct answer: A p-value summarizes incompatibility with a specified null model; it is not the probability that B beats A. A Bayesian probability of improvement is conditional on the likelihood and prior. Report effect size and uncertainty with either approach, and distinguish any positive lift from a gain large enough to justify switching costs and operational risks.
Check what was randomized
Define conversion, the observation window, eligible participants and the randomization unit before analyzing results. The calculations below assume independent users assigned once, complete outcomes, a stable conversion probability within each arm and no interference. Repeat visits counted as independent people, unequal follow-up or account-level randomization with user-level analysis can invalidate the stated uncertainty.
The hypothetical data are 200 conversions from 5,000 users in A and 235 from 5,000 in B. Rates are 4.0% and 4.7%: a difference of 0.7 percentage points, or 17.5% relative to A. Neither number alone describes how uncertain the true effect remains.
State the frequentist procedure precisely
For the null of equal rates, the NIST pooled two-proportion z test uses pooled rate 435/10,000 = 4.35%. Its standard error is 0.00407960 and z is 1.71586. The two-sided p-value is approximately 0.08619. This is a probability of a statistic at least as extreme under the null and the test assumptions, not an 8.6% probability that the null is true.
A separate large-sample unpooled Wald interval uses standard error 0.00407899. The approximate 95% interval for B−A is −0.0995 to +1.4995 percentage points. Its coverage interpretation concerns repeated use of the procedure. The ASA statement cautions against treating a p-value cutoff as the entire scientific or business conclusion.
Make the prior visible
Choose independent Beta(1,1) priors for illustration. With binomial data, the posterior rates are Beta(201,4801) for A and Beta(236,4766) for B. The PyMC A/B example explains this beta-binomial update and why prior choices matter. A uniform prior on each conversion rate is not uniform on relative uplift.
Posterior mean difference is 0.00699720 and its standard deviation is 0.00408593. Approximating the difference distribution as normal gives about 95.66% probability that B is better at all, but only 68.75% probability of improvement exceeding 0.5 percentage points. These are explicitly approximations; posterior integration or simulation can avoid the normal shortcut. They are not obtained by calling one minus the two-sided p-value a posterior probability.
Translate uncertainty into a decision
Estimate incremental contribution over a realistic rollout horizon and subtract implementation, support and reversal costs. Compare the posterior expected payoff or a prespecified frequentist decision rule with the value of obtaining more data. A high probability of a tiny improvement may still be commercially unhelpful, while a reversible low-cost change can justify a different decision from a costly migration.
Predefine metrics, exclusions and monitoring rules. Repeatedly applying fixed-sample significance thresholds after each new observation does not retain their nominal error guarantee. Bayesian posterior monitoring is a different question: a posterior probability threshold by itself does not promise a particular frequentist false-positive rate. Validate the chosen decision procedure, prior sensitivity, multiplicity and practical downside rather than assuming either framework makes optional stopping harmless.
Continue the analysis
Your checklist
- Verify independent randomization and complete observation windows.
- Report percentage-point and relative effects distinctly.
- Check prior and threshold sensitivity.
- Include switching cost and the cost of further evidence.
Sources & further reading
- NIST: Comparing two proportions
Pooled two-proportion z statistic under the null of equal proportions.
- ASA statement on statistical significance and p-values
A p-value is not the probability that a hypothesis is true, and a threshold alone does not establish practical importance.
- PyMC: Introduction to Bayesian A/B testing
Independent beta priors, binomial conversion likelihoods, posterior uplift and prior sensitivity.