Prompts Forms Resume Reports ★ Saved ★ Saved★ + Submit a tool
Core concepts

Bayes' Theorem

About 3170 characters Updated Nov 30, 2026 30 views AI wiki

Bayes' theorem is a formula in probability theory that describes the relation between conditional probabilities, showing how to update belief in a hypothesis after new evidence is obtained. It is the cornerstone of modern machine learning, causal inference and reasoning under uncertainty, and it is also a mathematical formalization of how humans rationally update beliefs.

Core Principles

The formula is: the posterior probability is proportional to the likelihood multiplied by the prior probability. Intuitively, after seeing evidence E, one's belief in hypothesis H depends on two things: how likely it is to see E when H holds, and how credible H itself was beforehand.

A classic example is a medical test: a disease with a prevalence of 1 percent, and a test with 99 percent sensitivity and 99 percent specificity. If a person tests positive, the probability that they actually have the disease is not 99 percent but about 50 percent. The reason is that the base of healthy people is far larger than that of patients, so the number of false positives is comparable to the number of true positives. This counterintuitive result is exactly the core value of Bayesian reasoning: the prior base rate cannot be ignored.

The Bayesian approach has two branches: one as an inference tool, using a prior distribution and observed data to obtain a posterior distribution which is then used for decisions; the other as an epistemological stance, holding that probability is a degree of belief rather than a long-run frequency. The frequentist school understands probability as the limiting frequency of repeated trials, and the two have long coexisted in statistical practice.

Key Points

Four components: prior, likelihood, evidence (marginal likelihood) and posterior. The evidence term usually serves as a normalization constant, so when comparing hypotheses one only needs to compare the products of prior and likelihood.

Conjugate priors: for computational convenience one often chooses a prior distribution conjugate to the likelihood, such as a beta prior for the binomial distribution or a normal prior for the normal distribution, so that the posterior has an analytical solution.

Naive Bayes: it assumes that features are conditionally independent given the class; although this assumption usually does not hold, it performs robustly on tasks such as text classification and is a classic baseline model.

Bayesian deep learning: it introduces distributions over network weights and approximates the posterior with variational inference or Monte Carlo sampling in order to obtain uncertainty estimates, which is especially important in high-risk scenarios such as healthcare and autonomous driving.

Cognitive bias: base-rate neglect and confirmation bias can both be seen as departures from Bayesian updating; the research of Kahneman and Tversky revealed systematic differences between human intuition and normative Bayesian reasoning.

Common Misconceptions

Misconception one: treating Bayes' theorem as a tool for arbitrary subjective assertion. The choice of prior requires justification and sensitivity analysis; it is not set at will. Misconception two: that the prior "contaminates" conclusions. When data are sufficient the posterior is usually dominated by the likelihood and the influence of the prior weakens; when data are sparse the prior precisely provides necessary regularization. Misconception three: confusing P(A|B) with P(B|A), the most typical reasoning error in medicine and law.

Application Scenarios

Medical diagnosis, spam filtering, evaluation of legal evidence, recommendation systems, fault diagnosis, A/B experiment analysis, risk pricing, and uncertainty quantification and active learning.