Fiveable

๐Ÿ“ŠAP Statistics Unit 8 Review

QR code for AP Statistics practice questions

8.4 Expected Counts in Two Way Tables

8.4 Expected Counts in Two Way Tables

Written by the Fiveable Content Team โ€ข Last updated June 2026
Verified for the 2027 exam
Verified for the 2027 examโ€ขWritten by the Fiveable Content Team โ€ข Last updated June 2026
๐Ÿ“ŠAP Statistics
Unit & Topic Study Guides

Previous Exam Prep

AP Cram Sessions 2021

Pep mascot

Expected counts tell you what a two-way table would look like if the null hypothesis were true (no association or no difference between groups). For any cell, the expected count is (row total)(column total)/table total.

Why This Matters for the AP Statistics Exam

Expected counts are the bridge between a two-way table and a chi-square test. You cannot calculate the chi-square statistic or check conditions without them, so this skill feeds directly into the larger chi-square work in Unit 8.

On the exam, expected counts show up in two main ways. In multiple-choice, you may need to compute a single expected cell value or recognize the correct formula. In free-response inference problems, expected counts matter because one of the chi-square conditions is that all expected counts (not observed counts) are at least 5. Showing how you found an expected count is important for clear exam work when you justify conditions or set up the chi-square statistic.

Key Takeaways

  • The expected count formula for any cell is expected count = (row total)(column total)/table total.
  • Expected counts represent the table you would expect if the null hypothesis (independence or homogeneity) were true.
  • You need expected counts to calculate the chi-square statistic and to check the large counts condition.
  • The large counts condition requires all expected counts to be at least 5, using expected counts, not observed counts.
  • Expected counts often come out as decimals, and that is fine. Do not round them to whole numbers before computing chi-square.
  • The same expected count formula works for both the test for independence and the test for homogeneity.

How Two-Way Tables Work

A two-way table (also called a contingency table) organizes counts for two categorical variables. Here is an observed counts table for car type and gender:

GenderSUVSports CarTotals
Male392160
Female11763180
Totals15684240

The numbers along the edges are the marginal totals: row totals (60 and 180), column totals (156 and 84), and the table total, or grand total (240).

Chi-square tests on two-way tables come in two types, and choosing the right one depends on how the data were collected.

Test for Homogeneity

A chi-square test for homogeneity compares the distribution of one categorical variable across two or more separate groups or populations. The null hypothesis is that the distribution of the categorical variable is the same across all the groups. Use this when you sampled from different populations or used a randomized experiment and want to compare them.

Test for Independence

A chi-square test for independence examines whether two categorical variables are associated within a single population. The null hypothesis is that the two variables are independent, meaning the value of one variable does not affect the distribution of the other. Use this when you took one sample from one population and recorded two variables for each individual.

Both tests use the same chi-square statistic and the same expected count calculation, so the formula below works no matter which test you choose.

Calculating Expected Counts

For each cell in the table, the expected count is:

expected count = (row total)(column total)/table total

where the table total is the grand total of all cells.

This formula comes from the idea of independence. If the variables were independent, the expected probability of a cell would be (row proportion)(column proportion), and multiplying that probability by the table total gives the expected count.

Worked Example

Use the observed table above to find the expected count for the Male/SUV cell.

  • Row total for Male = 60
  • Column total for SUV = 156
  • Table total = 240

So the expected count is:

(60)(156)/240 = 9360/240 = 39

Repeat this for every cell to build the full expected counts table:

GenderSUVSports Car
Male3921
Female11763

In this case the expected counts happen to match the observed counts exactly, which means the observed table is already what you would expect under independence. With most real data the expected counts will differ from the observed counts and often will be decimals.

How to Use This on the AP Statistics Exam

Problem Solving

  • Identify the row total, column total, and table total before plugging into the formula. Mislabeling these is the most common error.
  • Keep expected counts as decimals. Rounding too early changes your chi-square value.
  • When asked to check conditions, look at every expected count and confirm each one is at least 5.

Free Response

  • When you verify the large counts condition, state clearly that all expected counts are at least 5, not all observed counts.
  • Showing at least one expected count calculation makes your condition check and your setup easy to follow.
  • After you find expected counts, you use them inside the chi-square statistic ฯ‡ยฒ = ฮฃ(observed - expected)ยฒ/expected, so accurate expected counts carry through the whole problem.

Common Trap

  • A large p-value later in the test does not let you say there is "no association." The most you can conclude is that there is not enough evidence of an association. Expected counts set up that test, but they do not let you accept the null hypothesis.

Common Misconceptions

  • Checking observed counts instead of expected counts. The large counts condition uses expected counts of at least 5. Observed counts can be below 5 and the condition can still be met.
  • Rounding expected counts to whole numbers. Expected counts are theoretical and are usually decimals. Keep them exact when computing chi-square.
  • Confusing the formula. The correct formula is (row total)(column total)/table total. Do not divide by a row or column total instead of the grand total.
  • Mixing up the two tests. Independence uses one sample from one population with two variables. Homogeneity compares separate groups or populations. The expected count formula is the same, but the setup and hypotheses differ.
  • Thinking expected counts must differ from observed counts. Sometimes they match, which simply means the observed data already line up with what independence predicts.

Vocabulary

The following words are mentioned explicitly in the College Board Course and Exam Description for this topic.

Term

Definition

categorical data

Data that represents categories or groups rather than numerical measurements, such as colors, types, or classifications.

expected count

The theoretical frequency in each cell of a contingency table that would be expected if the null hypothesis of independence or homogeneity were true.

two-way table

A table that displays the frequency distribution of two categorical variables, organized in rows and columns.

Frequently Asked Questions

How do you find expected counts in a two-way table?

For any cell, multiply the row total by the column total, then divide by the table total: expected count = (row total)(column total) / table total.

What are expected counts in AP Statistics?

Expected counts are the counts you would expect in each cell of a two-way table if the null hypothesis were true, usually independence or the same distribution across groups.

What is the expected counts formula?

The expected count formula is (row total)(column total) / table total. Use the marginal totals from the observed table to calculate each expected cell count.

Are expected counts the same as observed counts?

No. Observed counts are the actual data in the table. Expected counts are calculated from row totals, column totals, and the table total under the null hypothesis.

Why do expected counts matter for chi-square tests?

Chi-square tests compare observed counts to expected counts. You also need expected counts to check the large counts condition, which requires every expected count to be at least 5.

Can expected counts be decimals?

Yes. Expected counts often come out as decimals. Keep the decimals when calculating the chi-square statistic instead of rounding them to whole numbers.

Pep mascot
Upgrade your Fiveable account to print any study guide

Download study guides as beautiful PDFs โ†’ See example

Print or share PDFs with your students

Always prints our latest, updated content

Mark up and annotate as you study

Click below to go to billing portal โ†’ update your plan โ†’ choose Yearlyโ†’ and select "Fiveable Share Plan". Only pay the difference

Plan is open to all students, teachers, parents, etc
Pep mascot
Upgrade your Fiveable account to export vocabulary

Download study guides as beautiful PDFs โ†’ See example

Print or share PDFs with your students

Always prints our latest, updated content

Mark up and annotate as you study

Plan is open to all students, teachers, parents, etc
report an error
description

screenshots help us find and fix the issue faster (optional)

add screenshot