How to Do Stem and Leaf: A Step‑by‑Step Guide to Creating and Interpreting Stem‑and‑Leaf Plots
A stem‑and‑leaf plot is a simple yet powerful way to display numerical data while preserving the original values. Unlike histograms that group data into bins, a stem‑and‑leaf plot shows each observation, making it easy to see the shape of the distribution, identify outliers, and calculate basic statistics at a glance. This article walks you through everything you need to know—from the basic concept to creating your own plot, interpreting the results, and avoiding common pitfalls. By the end, you’ll be able to construct a stem‑and‑leaf diagram confidently and use it as a quick‑look tool for exploratory data analysis.
Understanding Stem‑and‑Leaf Plots
A stem‑and‑leaf plot splits each data point into two parts:
- Stem – all but the final digit (usually the leading digit(s)).
- Leaf – the final digit (often the units place).
Here's one way to look at it: the number 57 becomes a stem of 5 and a leaf of 7. When you list all stems in a column and attach the corresponding leaves to the right, you obtain a compact visual that retains the exact data values Easy to understand, harder to ignore..
Why Use a Stem‑and‑Leaf Plot?
- Preserves raw data – you can reconstruct the original dataset from the plot.
- Shows distribution shape – similar to a histogram but with finer granularity.
- Highlights gaps, clusters, and outliers – easy to spot unusual values.
- Quick to draw by hand – ideal for small to moderate data sets (typically up to 50‑100 observations).
Steps to Create a Stem‑and‑Leaf Plot
Follow these systematic steps to turn any list of numbers into a clear stem‑and‑leaf diagram.
1. Organize Your Data
- Sort the data set in ascending order. Sorting makes it easier to assign leaves to the correct stems and to see patterns.
2. Determine the Stem Unit
- Decide what place value will serve as the stem. Most commonly, the tens place is used (e.g., for numbers 0‑99).
- If your data range is larger (e.g., 0‑999), you might use the hundreds place as the stem and the tens as the leaf, or you can create two‑digit stems (e.g., 45 | 6 for 456).
3. List the Stems
- Write all possible stem values in a vertical column, from smallest to largest, leaving a gap to the right for the leaves.
- Include stems even if they have no leaves; this shows empty intervals and helps visualize gaps.
4. Attach the Leaves
- For each data point, place its leaf (the last digit) next to the appropriate stem.
- If multiple observations share the same stem and leaf, repeat the leaf that many times (or use a frequency notation if you prefer).
5. Add a Key
- Include a legend that explains how to read the plot (e.g., “5 | 7 = 57”). This prevents confusion, especially when using non‑standard stem units.
6. Optional: Order the Leaves
- Some practitioners sort the leaves within each stem from smallest to largest for a cleaner look. This step is not required but improves readability.
Example Walkthrough
Let’s create a stem‑and‑leaf plot for the following data set (representing test scores out of 100):
62, 75, 68, 90, 85, 73, 77, 81, 69, 74, 88, 92, 67, 79, 83, 76, 91, 68, 75, 84
Step 1: Sort the Data
62, 67, 68, 68, 69, 73, 74, 75, 75, 76, 77, 79, 81, 83, 84, 85, 88, 90, 91, 92
Step 2: Choose Stem Unit
- Since the scores are two‑digit numbers, we use the tens digit as the stem and the units digit as the leaf.
Step 3: List Stems
Stems needed: 6, 7, 8, 9
6 |
7 |
8 |
9 |
Step 4: Attach Leaves
- 62 → leaf 2 on stem 6
- 67 → leaf 7 on stem 6
- 68 → leaf 8 on stem 6 (twice)
- 69 → leaf 9 on stem 6
Continue similarly for the other stems.
Result after attaching all leaves (unsorted within stems):
6 | 2 7 8 8 9
7 | 3 4 5 5 6 7 9
8 | 1 3 4 5 8
9 | 0 1 2
Step 5: Order the Leaves (optional)
6 | 2 7 8 8 9
7 | 3 4 5 5 6 7 9
8 | 1 3 4 5 8
9 | 0 1 2
Step 6: Add a Key
Key: 6 | 2 = 62
Interpretation at a glance:
- The most frequent scores lie in the 70‑79 range (seven observations).
- There are no scores in the 50‑59 range (stem 5 missing).
- The highest scores are 90, 91, and 92.
Interpreting the Plot
Once your stem‑and‑leaf diagram is complete, you can extract several insights:
| Feature | What to Look For | What It Tells You |
|---|---|---|
| Shape | Symmetric, skewed left/right, bimodal | Indicates distribution type (e.g., normal, skewed). |
| Center | Median lies near the middle leaf; you can count to find it. |
7. Assessing Spread
| Feature | What to Look For | What It Tells You |
|---|---|---|
| Range | Subtract the smallest leaf from the largest leaf (or from the largest full value). Which means | Gives the overall variability of the data. |
| Inter‑quartile Range (IQR) | Count leaves to locate the first quartile (Q1) and third quartile (Q3). The IQR = Q3 − Q1. | Shows the middle 50 % of the observations and is a strong measure of dispersion. Day to day, |
| Density | Observe how tightly leaves cluster around a stem. | Dense stems indicate a high frequency of values; sparse stems suggest gaps. |
Example: In the test‑score plot above, the range is 92 − 62 = 30 points. The median (the 10th value) falls on the 7‑stem, and Q1 and Q3 can be approximated by counting leaves, giving an IQR of roughly 8 points. This tells us that most scores are clustered within an 8‑point window around the median Worth keeping that in mind..
8. Spotting Gaps and Outliers
- Gaps appear as stems with no leaves (or a noticeable jump in leaf values).
- Outliers are values that lie far from the main body of data, often visible as isolated stems at the extremes or as leaves that are far from neighboring leaves within the same stem.
Identifying these patterns helps you decide whether to investigate data entry errors, consider separate subpopulations, or apply transformations before further analysis That's the whole idea..
9. Comparing Multiple Data Sets
When you have two or more groups, you can place their leaves side‑by‑side using a double‑stem format or separate panels:
Stem | Group A | Group B
6 | 2 7 8 8 9 | 0 1 3
7 | 3 4 5 5 6 7 9 | 2 4 6
- Aligning stems makes it easy to see which group has higher or lower values, more spread, or distinct clusters.
10. Using Technology
While stem‑and‑leaf plots are traditionally drawn by hand, many statistical packages can generate them automatically:
| Software | Command (example) |
|---|---|
| R | stem(data, scale = 1) |
| Python (SciPy) | import scipy.Here's the thing — stem(data) |
| Excel | Use the “Analysis ToolPak” → “Histogram” and add a custom bin range. That said, stats as stats; stats. |
| Tableau / Power BI | Drag a “Numeric” field to the “Rows” shelf and choose “Stem‑and‑Leaf” from the visualization types. |
Easier said than done, but still worth knowing.
These tools can handle large data sets and allow you to adjust stem units on the fly, preserving the plot’s visual clarity while saving time.
11. When to Prefer a Stem‑and‑Leaf Plot
| Situation | Reason to Use Stem‑and‑Leaf |
|---|---|
| Small‑to‑moderate data sets (≤ 200 observations) | Retains original values for exact reconstruction. |
| Exploratory data analysis | Quickly reveals shape, center, spread, and outliers. |
| Teaching introductory statistics | Visual intuition without sacrificing precision. |
| Need to preserve raw data | Unlike histograms, no loss of individual observations. |
For very large samples, consider supplementing with a histogram or box plot, but keep a stem‑and‑leaf view for a subset of the data if you need to inspect specific values.
Conclusion
The stem‑and‑leaf plot is a versatile, low‑tech tool that bridges the gap between raw data and graphical insight. By separating each observation into a stem (the leading digits) and a leaf (the trailing digit), you create a compact display that preserves the exact values while instantly revealing the distribution’s shape, central tendency, variability, and any notable gaps or outliers. Whether you sketch it on paper, generate it with software, or compare multiple groups side‑by‑side, the stem‑and‑leaf diagram remains a valuable first step in any exploratory analysis, offering both clarity for teaching and precision for professional work.