← MATH 380 MathScape 0 MATH380

Histograms

19 min read

Jump to a section
Textbook: Moore, McCabe, Craig, Introduction to the Practice of Statistics (IPS), 9th edition  •  Chapter: 1  •  Section: 2

Quick Reference

Field Value
Textbook Moore, McCabe, Craig, Introduction to the Practice of Statistics (IPS), 9th edition
Location Chapter 1 (Looking at Data: Distributions), Section 1.2 (Displaying Distributions with Graphs)
Subsection Displaying quantitative variables with a histogram
Pages Page numbers pending faculty verification.
Course MATH380
Role First graph for quantitative data. It is the picture students will read for the rest of Chapter 1 when they describe shape, center, and spread, and it is the discrete cousin of the density curve in Section 1.4.

Try This First

Here are the ages, in whole years, of 20 people waiting in a clinic lobby.

4   6   9   11  12  14  18  19  21  22
23  25  27  31  34  36  41  48  52  63

Before reading any definition, do three things on paper.

  1. Group the ages into classes 10 years wide: 0 to under 10, 10 to under 20, 20 to under 30, and so on up to 60 to under 70. Count how many ages fall in each class.
  2. Draw a horizontal axis for age and a vertical axis for the count. Over each class, draw a bar whose height is its count, and let neighboring bars touch.
  3. Predict, before you finish drawing: where will the tallest bar sit, and will the picture lean to one side?
Check your three answers

The counts by class:

Class (age) Count
0 to under 10 3
10 to under 20 5
20 to under 30 5
30 to under 40 3
40 to under 50 2
50 to under 60 1
60 to under 70 1
Total 20

The counts add to 20, which is the number of people, so no age was dropped or double counted. Two classes tie for the tallest bar, the 10-to-under-20 class and the 20-to-under-30 class, each with a count of 5. The picture has a longer tail stretching to the right, toward the older ages, so it leans (is skewed) to the right.

A wrong turn while grouping is common and worth understanding. The most frequent slip is an age landing in two classes at once, or in none, because the class boundaries were not stated clearly. There is no need to rush this. Deciding once, in plain words, which class an exact boundary value belongs to is what makes a histogram unambiguous, and the next section turns that decision into a rule.


The Big Idea: A Histogram Is a Distribution Drawn to Scale

A quantitative variable can take many distinct values, often too many to list one bar per value. A histogram solves that by slicing the number line into adjacent classes of equal width and reporting how the data spread across those classes.

Think of a histogram as a small process. The input is a list of numbers. The process sorts each number into the one class that contains it, counts the numbers in each class, and draws a bar whose height is that count. The output is a single picture of the whole distribution: where the data cluster, how far they reach, and whether they lean to one side.

Two features make this picture honest and readable:

Two representations of the same distribution

Representation What it shows
Frequency table Each class and its count, in exact numbers
Histogram The same counts as bar heights, as a shape the eye reads at once

Translate both directions. Given the table from the opener, you should be able to point to the two tallest bars and the right-leaning tail. Given a finished histogram, you should be able to read each bar height back into a count and rebuild the table.


Prerequisite Hub

Builds on

A histogram pulls together four earlier skills. Each link below opens the node it names.

Unlocks

Cross-course prerequisites


The Official Definition

Histogram. A histogram displays the distribution of a quantitative variable by dividing the range of values into classes (intervals) of equal width and drawing a bar over each class whose height is the count or the percent of observations falling in that class. Because the classes are adjacent intervals on a numerical scale, the bars touch with no gaps between them.

Source: Moore, McCabe, Craig, IPS 9th edition, Section 1.2 (Displaying Distributions with Graphs); corroborated by OpenStax Introductory Statistics 2e, histogram defined as an x-y display of a data set where x is the data and y is the frequency or relative frequency (https://openstax.org/books/introductory-statistics-2e/pages/2-key-terms).

There are no named theorems for this skill. What follows directly from the definition are two arithmetic facts worth keeping in view:

\[ \text{percent in class} = 100 \cdot \frac{n_{\text{class}}}{n}. \]

Switching from counts to percents changes only the vertical scale, not the shape. The 20-to-under-30 class above holds $\frac{5}{20} = 0.25$ of the data, which is $25\%$; the bars that were tallest in counts are still tallest in percents.


Choosing Classes and Boundary Rules

A histogram is a choice, not a fixed object. Two reasonable people can draw different histograms of the same data by choosing different class widths, and both can be correct. The choices that have to be made:

State the boundary rule before counting. The most common counting error is an exact boundary value placed in two classes or in none, which throws off every count and the total.


Histogram Versus Bar Graph

These two pictures look similar and are constantly confused, yet they display different kinds of data and follow different drawing rules.

Feature Histogram Bar graph
Variable type Quantitative (numbers) Categorical (labels)
Horizontal axis A numerical scale, divided into classes A list of category names, in any order
Bars Touch (no gaps), because classes are adjacent Have gaps, because categories are separate
Width meaning Width is the class interval and is equal across bars Width carries no meaning
Order of bars Fixed by the number line Can be rearranged freely

The single fastest check: if the bars touch and the horizontal axis is a number line, it is a histogram; if the bars are separated and the horizontal axis lists names, it is a bar graph.


Worked Examples

Example 1: From counts to a histogram, and reading it back

Twelve quiz scores out of 20 are recorded:

7   8   9   11  12  12  13  14  15  16  18  19

Build a histogram with classes 5 units wide starting at 5: 5 to under 10, 10 to under 15, 15 to under 20.

Predict first. The scores bunch in the low teens, so expect the middle class to be the tallest.

Build the table. Sort each score into its class using the “include the lower endpoint, exclude the upper” rule.

Class (score) Tally Count
5 to under 10 7, 8, 9 3
10 to under 15 11, 12, 12, 13, 14 5
15 to under 20 15, 16, 18, 19 4
Total 12

Draw the bars. Over each class draw a bar at its count height; the bars touch because the classes are adjacent.

count
  5 |        ┌─────┐
  4 |        │     │┌─────┐
  3 |  ┌─────┤     ││     │
  2 |  │     │     ││     │
  1 |  │     │     ││     │
  0 +--┴─────┴─────┴┴─────┴----- score
       5    10    15    20

Check against the prediction. The middle class (10 to under 15) is tallest with a count of 5, matching the prediction. The counts add to $3 + 5 + 4 = 12$, the number of scores, so nothing was dropped. Reading the picture back gives exactly the table, which is the test that the histogram is faithful.

Example 2: The same data as a percent histogram

Convert the quiz-score histogram above to percents. The total is $n = 12$.

Predict first. Switching to percents rescales the vertical axis but keeps the shape, so the middle class stays tallest and the percents must add to 100.

Compute each share.

Class Count Proportion $\frac{n_{\text{class}}}{12}$ Percent
5 to under 10 3 $3/12 = 0.25$ $25\%$
10 to under 15 5 $5/12 \approx 0.417$ $\approx 41.7\%$
15 to under 20 4 $4/12 \approx 0.333$ $\approx 33.3\%$
Total 12 1.00 100%

Check. The proportions add to $0.25 + 0.417 + 0.333 = 1.00$ and the percents add to about 100. The tallest bar is still the middle class. Only the axis label changed, from “count” to “percent.”

Example 3: How the class width changes the picture

Take eight measurements:

2   3   3   4   5   6   8   9

Build two histograms, one with width 2 and one with width 4, and compare.

Width 2 (classes 2 to under 4, 4 to under 6, 6 to under 8, 8 to under 10):

Class Count
2 to under 4 3
4 to under 6 2
6 to under 8 1
8 to under 10 2

Width 4 (classes 2 to under 6, 6 to under 10):

Class Count
2 to under 6 5
6 to under 10 3

What changed. Both histograms describe the same eight numbers, and both sets of counts add to 8. The width-2 picture shows a small dip in the middle (the 6-to-under-8 class is lowest); the width-4 picture flattens that detail into two bars and hides the dip. Wider classes smooth the shape and can erase real structure; narrower classes show more detail but can look ragged with few data. Neither is wrong; they answer the question at different resolutions, which is exactly why the class width is a reported choice.

Example 4: Reading a histogram without the raw data

A histogram of the wait times (in minutes) for 50 callers has these bar heights, read off the vertical count axis:

Class (minutes) Count
0 to under 5 18
5 to under 10 14
10 to under 15 9
15 to under 20 5
20 to under 25 4

Answer three questions from the picture alone.

(a) Do the counts account for all 50 callers? Sum the heights: $18 + 14 + 9 + 5 + 4 = 50$. Yes, every caller is counted once.

(b) What percent of callers waited under 10 minutes? The first two classes cover 0 to under 10 minutes, with $18 + 14 = 32$ callers. As a percent, $\frac{32}{50} \times 100 = 64\%$.

(c) Which way does the distribution lean? The tall bars sit on the left (short waits) and the bars shrink toward the right (long waits), so the distribution is skewed to the right. A few long waits stretch the tail without a matching number of very short-then-shorter waits on the other side.


Common Misconceptions

Common misconception

a histogram is a literal picture of the data values. The height of a bar is not a data value; it is a count of how many values fall in that class. A bar of height 5 does not mean a value of 5, and a tall bar does not mean large numbers. The horizontal position locates the values; the vertical height counts them. Confusing the two leads a reader to say “the data go up to 5” when the tallest bar simply holds 5 observations. Read the two axes as answering two different questions: where (horizontal) and how many (vertical).

Common misconception

a histogram and a bar graph are the same chart. They display different data and follow different rules. A histogram is for quantitative data on a number line and its bars touch; a bar graph is for categorical labels and its bars are separated by gaps. Drawing gaps between histogram bars falsely suggests empty stretches of the number line, and ordering bar-graph categories as if they were numbers reads meaning into an order that is not there. The check is the horizontal axis: a number line means histogram, a list of names means bar graph.

Common misconception

unequal class widths are fine as long as the heights are counts. When classes have different widths, a count height stops being comparable across bars, because a wider class catches more values just by being wider, not because the data cluster there. Equal width is what lets the eye read “taller equals more data.” Statistics handles unequal widths with density (area, not height), which is the bridge to the density curve in Section 1.4; for the histograms in this section, keep every class the same width.


Practice Problems

Level 1 Histogram or Bar Graph?

A chart has a horizontal axis labeled “favorite pizza topping” with bars for pepperoni, mushroom, and cheese, and the bars are separated by gaps. Is this a histogram or a bar graph? Give the one feature that decides it.

Show Answer

It is a bar graph. The deciding feature is the horizontal axis: it lists category names (a categorical variable), not a number line. The gaps between bars confirm it, because categorical bars are drawn separated. A histogram would have a numerical scale on the horizontal axis and bars that touch.

Level 2 Build the Frequency Table

Here are 10 test scores: 52, 61, 63, 68, 74, 75, 79, 83, 88, 91. Using classes 10 units wide starting at 50 (50 to under 60, 60 to under 70, and so on), build the count for each class and confirm the total.

Thought Process

Apply the “include the lower endpoint, exclude the upper” rule to each score. Predict first: the scores spread fairly evenly across the 60s, 70s, and 80s, so expect no single class to dominate. The counts must add to 10.

Show Answer
Class (score) Count
50 to under 60 1
60 to under 70 3
70 to under 80 3
80 to under 90 2
90 to under 100 1
Total 10

Check: $1 + 3 + 3 + 2 + 1 = 10$, the number of scores. The middle two classes (60s and 70s) tie for tallest, matching the prediction of no single dominant class.

Level 3 Counts to Percents

A histogram of 40 commute times has class counts 6, 14, 12, 6, and 2. Convert each class to a percent of the 40 commuters and confirm the percents close to 100.

Show Answer

Each percent is the count divided by 40, times 100.

Class Count Percent
1 6 $6/40 \times 100 = 15\%$
2 14 $14/40 \times 100 = 35\%$
3 12 $12/40 \times 100 = 30\%$
4 6 $6/40 \times 100 = 15\%$
5 2 $2/40 \times 100 = 5\%$
Total 40 100%

Check: $15 + 35 + 30 + 15 + 5 = 100$. The percents close, so the conversion is consistent. The shape (tallest in class 2, shrinking toward class 5) is identical to the count histogram, because only the vertical scale changed.

Level 4 Read the Picture

A histogram of 60 daily high temperatures (in degrees Fahrenheit) has these class counts:

Class Count
30 to under 40 4
40 to under 50 10
50 to under 60 22
60 to under 70 16
70 to under 80 8

(a) Confirm the counts account for all 60 days. (b) What percent of days had a high of at least 60 degrees? (c) Is the distribution roughly symmetric, skewed left, or skewed right? Justify the answer from the bar heights.

Thought Process

For (a), sum the heights and compare to 60. For (b), “at least 60 degrees” covers the 60-to-under-70 and 70-to-under-80 classes, so add those counts and convert to a percent of 60. For (c), find the tallest bar and check whether the bars fall off faster on one side than the other.

Show Answer

(a) $4 + 10 + 22 + 16 + 8 = 60$. The counts account for all 60 days.

(b) At least 60 degrees covers the last two classes: $16 + 8 = 24$ days. As a percent, $\frac{24}{60} \times 100 = 40\%$.

(c) The tallest bar is the 50-to-under-60 class (count 22), near the middle. Moving away from it, the heights fall off to 10 and then 4 on the left, and to 16 and then 8 on the right. The fall-off is similar on both sides, so the distribution is roughly symmetric with no long one-sided tail.

Level 5 Why Class Width Matters

A data set of 16 reaction times (in tenths of a second) is:

2   2   3   3   4   4   4   5   6   7   8   8   9   9   10  10

(a) Build a histogram with width 1 (classes 2 to under 3, 3 to under 4, and so on through 10 to under 11). (b) Build a histogram with width 3 (classes 2 to under 5, 5 to under 8, 8 to under 11). (c) Explain what the wide-class picture hides that the narrow-class picture reveals, and state which width you would report and why.

Thought Process

Sort each value into its class under the “include the lower endpoint, exclude the upper” rule. Both histograms must have counts that add to 16. Predict first: there appear to be two clusters, one in the low values and one in the high values, with a thin middle. Watch whether the wide classes preserve or erase that gap.

Show Answer

(a) Width 1:

Class Count
2 to under 3 2
3 to under 4 2
4 to under 5 3
5 to under 6 1
6 to under 7 1
7 to under 8 1
8 to under 9 2
9 to under 10 2
10 to under 11 2
Total 16

The counts dip to 1 across the middle classes (5, 6, and 7), with heavier counts at the low end and the high end.

(b) Width 3:

Class Count
2 to under 5 7
5 to under 8 3
8 to under 11 6
Total 16

Both totals are 16, so neither picture loses data.

(c) The width-1 histogram reveals a thin middle: three consecutive classes (5, 6, 7) each hold just one value, suggesting two clusters of reaction times with a sparse gap between them. The width-3 histogram still shows the middle class as the shortest (count 3), so a careful reader sees the dip, but the three thin middle classes are merged into one bar and the sharpness of the gap is softened. For this data set the width-1 histogram is the better report, because the structure worth seeing (two clusters) appears at a finer resolution than width 3 can show. The general lesson: when a feature matters, choose a class width fine enough to display it, then confirm the shape is stable if you widen the classes slightly.


Ask Why


Mastery Checklist

Novice (Level 1-2):

Competent (Level 3-4):

Proficient (Level 5):


Connections

Looking back:

Looking ahead:

Real-world connections:


Resources



Last updated: 2026-06-16