Unit 1 · Topic 1.5 · about 20 minutes
Graphical Representations for One Quantitative Variable
Build a dotplot, a stem-and-leaf plot and a histogram by hand, and choose bins that show the data honestly.
Predict first
A math teacher asked the 33 teachers at her school how many minutes their drive to school takes. She makes two histograms of the same 33 times, one with bins 20 minutes wide and one with bins 5 minutes wide. What will be different?
Displays that keep the number line
A quantitative variable takes numerical values, so its graphs keep those values in their natural order on a number line, smallest to largest. That is the big difference from a bar chart, where you can put the categories in any order. Each display in this lesson shows how often each value, or each interval of values, occurs: its frequency or its relative frequency.
The first three displays all use the same data, the teachers' drive times in minutes.
Dotplots
A dotplot puts one dot above a number line for each observation, at that observation's value. (It can also run up a vertical axis, with the dots beside it.) When values repeat or nearly repeat, the dots stack. You can read every value back off a dotplot, which makes it a strong choice for small data sets.
Drive times of 33 teachers
Each dot is one teacher. One group lives within about 15 minutes of school, and a larger group drives 25 minutes or more.
Stem-and-leaf plots
A stem-and-leaf plot splits each value into a stem, the leading digit or digits, and a leaf, usually the single digit after the stem. For the drive times, the tens digit is the stem and the ones digit is the leaf, so 32 minutes becomes stem 3, leaf 2. The stems run down the side in order, and the leaves on each row are written in order too.
Like a dotplot, a stemplot keeps every value. It also works as a sideways histogram with bins 10 wide. Always include a key, so a reader knows that 3 | 2 means 32 minutes and not 3.2.
Drive times of 33 teachers. Key: 3 | 2 means 32 minutes.
Histograms
A histogram sorts the values into intervals of equal width, called bins, along the horizontal axis. Each bar covers one bin, and its height is the number of values in that bin, or the proportion of values in a relative frequency histogram. The bars touch, because the bins cover the number line with no space between them. A histogram can also be turned sideways, with the bins up the vertical axis and the bars running horizontally.
Settle the boundaries before you count. The usual convention puts a value that falls exactly on a boundary into the bin that starts there, so a 40-minute drive counts in the 40 to 45 bin, not the 35 to 40 bin.
A histogram gives up the individual values, which is why it handles large data sets where a dotplot would turn into a blur. The price is that the bin width changes the picture. Here are the same 33 drive times twice.
Bins 20 minutes wide
Bins 5 minutes wide
With wide bins the two groups merge into one lump. Narrow bins show that no teacher drives between 15 and 25 minutes.
There is no single correct bin width. Too wide, and real features vanish into one bar, as above. Too narrow, and most bars hold one or two values, so the shape breaks up into noise. Try a few widths and keep one that shows the pattern without inventing one.
Worked exampleBuilding a histogram from raw data
At the end of a school day, 24 students checked how much battery their phones had left, in percent: 12, 18, 23, 27, 31, 34, 36, 40, 41, 42, 45, 47, 48, 51, 53, 55, 58, 60, 64, 67, 71, 76, 83, 91. Make a histogram with bins 20 percentage points wide.
Set the bins. Start at 0: 0 to 20, 20 to 40, 40 to 60, 60 to 80 and 80 to 100. A value on a boundary goes into the bin that starts there, so 40 belongs to 40 to 60 and 60 belongs to 60 to 80.
Count each bin. 0 to 20: 2 phones. 20 to 40: 5. 40 to 60: 10. 60 to 80: 5. 80 to 100: 2. The counts add to 24, so every phone was counted exactly once.
Draw the bars. Put battery percent on the horizontal axis and the number of phones on the vertical axis. Each bar spans the full width of its bin, touches its neighbors, and is as tall as its count.
Label it. Name the variable and its units under the horizontal axis, and say what the bar heights count beside the vertical axis.
Bars of heights 2, 5, 10, 5 and 2, drawn below. The battery levels pile up in the middle, around 40% to 60%, and thin out evenly on both sides.
Battery left at the end of the day, 24 phones
Check your understanding
A stem-and-leaf plot of the points a basketball player scored in each game has the row 2 | 0 3 3 8. Its key says 1 | 5 means 15 points. What does this row show?
Here are the heights, in centimeters, of 12 sunflowers: 142, 150, 155, 158, 160, 161, 165, 170, 170, 174, 180, 189. In a histogram with bins 10 centimeters wide starting at 140, how tall is the bar for the 160 to 170 bin? Each bin includes its left endpoint.
A website records the load time, in seconds, for each of 5,000 visits. Which display gives the clearest picture of the distribution of load times?
With bins 20 points wide, a histogram of 200 test scores shows one hump. With bins 5 points wide, it shows two peaks, and a dotplot of the same scores shows the same two groups. What is the best explanation?
Twenty-four students recorded how much battery their phones had left, in percent: 12, 18, 23, 27, 31, 34, 36, 40, 41, 42, 45, 47, 48, 51, 53, 55, 58, 60, 64, 67, 71, 76, 83, 91. In a relative frequency histogram with bins 20 points wide starting at 0, how tall is the bar for the 40 to 60 bin? Each bin includes its left endpoint.
Course alignment, for teachers
AP Statistics topic 1.5, Unit 1: Exploring One-Variable Data and Collecting Data.
- Skill 3.A: Construct tabular and graphical representations of data and distributions.