Stem and Leaf Plot

Generate a stem-and-leaf plot from numbers.

About the Stem and Leaf Plot

A stem and leaf plot shows the shape of a data set while keeping every original value visible, which a histogram throws away.

How to use it

  1. Enter your numbers separated by commas.
  2. The stems are the leading digits.
  3. Leaves are the final digits, in order.

The formula

A stem-and-leaf plot splits each number into two parts: the leading digits become the stem, the final digit becomes the leaf.

23 → stem 2, leaf 3  ·  31 → stem 3, leaf 1  ·  147 → stem 14, leaf 7

Leaves sharing a stem are listed together in order, so the plot shows the shape of the distribution while keeping every original value. That is the property that makes it different from a histogram: a histogram tells you eight values fall between 20 and 29, and a stem-and-leaf tells you which eight.

Because the values remain, you can read the median, the range and any outlier straight off the plot — no recalculation from raw data required.

Worked examples

StemLeavesRepresentsCount
23 5 823, 25, 283
31 4 4 731, 34, 34, 374
40 240, 422
5no values in the 50s0

Reading this plot: nine values, running from 23 to 42, with the bulk sitting in the 30s. The median is the fifth value, which counting through the leaves is 34. An empty stem is not omitted, and that matters — leaving out the 50s row would hide a gap in the data, and gaps are frequently the most interesting thing a distribution has to say.

Common mistakes

Terms explained

Stem
The leading digit or digits, shared by every value in the row.
Leaf
The final digit of a value, always a single digit.
Key
A note explaining the scale, such as '2 | 3 means 23'. Without one the plot is ambiguous.
Median
The middle value once the data is ordered. Easy to count off directly on this plot.
Split stem
Dividing a stem into two rows, 0-4 and 5-9, when too many leaves crowd one line.
Back-to-back plot
Two datasets sharing a central stem column, with leaves extending in both directions. Ideal for comparing two groups.

Common questions

How do I read a stem-and-leaf plot?
Join each stem to each of its leaves. A stem of 3 with leaves 1, 4, 4 and 7 represents 31, 34, 34 and 37.
What is the advantage over a histogram?
It keeps every original value. A histogram shows the shape and discards the numbers; this shows the shape and lets you recover the data, so the median and range can be read directly.
How do I find the median from the plot?
Count the values, find the middle position, then count through the leaves in order. With nine values, the median is the fifth leaf.
What if my numbers have three digits?
The stem takes the leading digits and the leaf takes the last. 147 is a stem of 14 and a leaf of 7. Always include a key so the scale is unambiguous.
Why is a key needed?
Because 2 | 3 could mean 23, 2.3 or 230. The key removes the ambiguity and is considered part of the plot, not an optional extra.
What is a split stem?
A stem divided into two rows — leaves 0 to 4 on one, 5 to 9 on the other. It spreads out data that would otherwise pile onto a few crowded lines.
Can I compare two groups?
Yes, with a back-to-back plot: one shared stem column, one group's leaves reading left and the other's reading right. It makes differences in centre and spread obvious at a glance.
When should I not use one?
With large datasets, or values spanning many orders of magnitude. Past roughly fifty values the plot becomes unwieldy and a histogram or box plot communicates better.

Related calculators

← All 51 calculators