Bayes Rule

Bayes Rule


This lesson will explain Bayes Rule.

See More
Introduction to Statistics

Get a load of these stats.
Our Intro to Stats course is only $329.

Sophia's online courses not only save you money, but also are eligible for credit transfer to over 2,000 colleges and universities.*
Start a free trial now.


Bayes' Rule

What's Covered

This tutorial will cover Bayes' Rule. You'll learn about:

  1. Bayes' rule

1. Bayes' Rule

Bayes' rule is a theorem that allows us to turn around a conditional probability statement.

Term to Know

Bayes Rule

A reversal of the conditional probability formula that asks "given that this second event happened, what is the probability that this other event occurred first?"

This rule allows you to update or revise your probabilities in light of new information. Essentially, it reverses the conditional probability formula, allowing you to find the probability of A given B from the probability of B given A.

Example  Suppose that my favorite game show is Go for Broke. The rules of the game are:

    1. The contestant gets to roll a die to determine which jar they're going to draw a colored chip from.
    2. If the chip is green, they will win a prize.
    3. If the chip is red, they won’t win anything.
    4. If the contestant rolls a 1 or a 2, they select from jar A, which contains 9 green chips and 12 red chips.
    5. If they roll a 3, 4, 5, or 6, they have to select from jar B, which only contains 5 green chips and 25 red.

Rolling a 1 or a 2 and selecting from jar A gives the contestant a better probability of winning a prize.

Here is the tree diagram of the probabilities in this game:

  • Contestants have a 1/3 probability of rolling a one or a two and a 2/3 probability of rolling anything else.
  • If they are selecting from jar A, they have a 9/21 probability of getting the green chip and a 12/21 probability of picking the red chip.
  • If they are selecting from jar B, they have a 5/30 for the green and a 25/30 probability for the red.

By multiplying out the values on the tree diagram, we find that we get these values for the probability of choosing either color chip from either jar:

Think About It

So suppose you tuned in late to Go for Broke one day and didn't get to see where the chip came from. All you see is that the contestant won the prize by getting the green chip.What's the probability that they rolled the 1 or 2 to select their winning chip from jar A, given that they got the green chip?

To answer that question, what you're actually trying to find is the probability that you would have picked from A, given that you got the green chip. This requires the conditional probability statement: probability of A given G is probability of A and G over probability of G:

The probability of A and G is one of the branches on the tree diagram. So it's probability of A times probability of G given A. And so what you're noticing is the probability of G given A helps us to find the probability of A given G.

When we actually go through and run the scenarios, this was one of the branches on the tree diagram. Probability of G can happen in two ways: selecting from jar A or from jar B. So the equation simplifies down to the fraction 9/16, as you can see here:

What that means is that, out of every 16 times you pick the green, 9 of those times it came from jar A. This is a surprising conclusion! The probability that you would pick from jar A, given that you ended up winning, is actually over half.

Example  Here's another example of when you might use Bayes' theorem that was used in an actual army practice to find the wreckage of a plane:

Suppose that a plane was going from Miami to Mexico City, but then it crashed somewhere in the Gulf of Mexico. Here is a map of the scenario:

As the map shows, the plane may have lost radio contact in one location. Therefore, because they don't know what else might have happened with the plane, the search party might start searching in that area. But maybe a few days go by and people find debris in a different location.

Bayes' theorem allows you to analyze the probability that the plane crashed in the region where they lost radio contact given that the debris was found elsewhere, where the green circle is. If that probability is low, you might choose to start searching in the green region, assuming that the plane tried to go around the storm by going north.

The idea is that we can update our guesses based on new information.


Bayes' rule is a mathematical theorem that allows you to amend probability statements based on new information. With this rule, you can turn around the conditional probability statement and find the probability of A given B from the probability of B given A. Therefore, it lets you use newer knowledge to adjust probabilities of prior events.

Thank you and good luck!


  • Bayes Rule

    A reversal of the conditional probability formula that asks "given that this second event happened, what is the probability that this other event occurred first?"