Skip to content
AP Statistics · Inference for Categorical Data: Proportions

Categorical data

Categorical data appears in 3 reviewed AP Statistics questions and sits in Inference for Categorical Data: Proportions. Below are worked examples showing exactly how the exam tests it, with the answer marked and every distractor explained.

How Categorical data is tested

Example 1Easier
A frequency table shows the following distribution of letter grades in a statistics class: A (5 students), B (12 students), C (8 students), D (3 students), F (2 students). A student creates a bar chart with the bars ordered A, B, C, D, F. Another student creates a pie chart of the same data. Which display is more appropriate and why?
  1. AThe bar chart is more appropriate because it preserves the natural ordering of grades and makes comparisons between categories easierCorrect
  2. BBoth displays are equally appropriate; the choice is purely aesthetic
  3. CNeither display is appropriate because the data are quantitative
  4. DThe pie chart is more appropriate because it shows proportions of a whole

Why A is right

Letter grades are ordinal categorical data with a natural ordering. A bar chart preserves this order and makes it easy to compare the frequencies of adjacent categories. While a pie chart can also display categorical data, bar charts are generally preferred for comparing categories, especially when order matters.
Why the other 3 choices miss
B
Incorrect because the natural ordering of grades and the ease of comparison make the bar chart more appropriate than a pie chart for this context.
C
Incorrect because letter grades are categorical (ordinal) data, and both bar charts and pie charts are appropriate displays for categorical data.
D
Incorrect because while pie charts do show proportions, they make it difficult to compare similar-sized categories and do not naturally convey the ordering of letter grades.
Example 2Medium
A researcher compares the distribution of political party preference (Democrat, Republican, Independent) between two cities using a chi-square test. Both cities are sampled independently. This test is a chi-square test for
  1. Ahomogeneity, because two independent populations are compared on one variableCorrect
  2. Bindependence, because party preference and city are both measured on the same individuals
  3. Cgoodness of fit, because party preference has three categories in each city sample
  4. Dassociation, because the test determines causation between city and party preference

Why A is right

A chi-square test for homogeneity compares the distribution of a categorical variable across two or more independently sampled populations. Here, the two cities are separate populations, and party preference is the categorical variable being compared. The question is whether the distribution of party preference is the same (homogeneous) in both cities.
Why the other 3 choices miss
B
Incorrect. A test for independence examines whether two variables measured on the same individuals are associated. Here, the two cities are separate samples, not two variables measured on the same people.
C
Incorrect. A goodness-of-fit test compares one sample's distribution to a hypothesized distribution. Having three categories does not make it goodness of fit; this test involves two samples, not one sample compared to a theoretical distribution.
D
Incorrect. Chi-square tests assess association, not causation. Furthermore, the correct classification is homogeneity (comparing distributions across populations), not simply 'association.'

Studied alongside

Other concepts from Inference for Categorical Data: Proportions.