Stem-and-Leaf Plot Generator
Paste your numbers and get a stem-and-leaf plot with a key, ordered leaves and every stem in between. Split the stems, put two data sets back to back, and handle decimals and negative values with the convention stated. Copy the plot as text or download it as an image. Free, no sign-up.
Decimals and negative numbers work. If your numbers use decimal commas, separate them with semicolons.
17 values
Text version
Stem | Leaf 1 | 2 5 2 | 1 4 4 7 3 | 0 2 3 5 8 8 4 | 1 3 7 5 | 2 6 Key: 1 | 2 = 12
Ordered data: 12, 15, 21, 24, 24, 27, 30, 32, 33, 35, 38, 38, 41, 43, 47, 52, 56
Digits finer than the leaf unit (1) are cut off, not rounded — the usual convention, from Tukey.
Labels and style
Takes the title out of the image and sets the figure number in bold and the title in italics above it — the APA 7 layout. The key stays inside the image, where APA puts a figure's legend.
How to Use the Stem-and-Leaf Plot Generator
- 1. Enter the data. Type or paste the numbers in any order, separated by commas, spaces or new lines. If your numbers use decimal commas, separate them with semicolons.
- 2. Choose the stems. Automatic makes the leaf the finest digit in your data, unless that would need more than 20 stems. Or choose the place values yourself: tens and ones (37 → 3 | 7), ones and tenths (3.7 → 3 | 7), and so on.
- 3. Adjust the display. Split the stems to spread out a crowded plot, decide whether digits beyond the leaf are cut off or rounded, and tick Compare two data sets back to back to add a second set on the left of the stems.
- 4. Copy or download. Copy the text version into a document or worksheet, or download the image as SVG or PNG. APA style moves the title out of the image and keeps the key inside it.
How to Read a Stem-and-Leaf Plot
Each value is split into a stem — every digit but the last — and a leaf, the last digit. The key says what the digits stand for: with Key: 1 | 2 = 12, the stems are tens and each leaf is a ones digit. The 17 quiz scores in the example become:
Quiz scores, stems are tens
Stem | Leaf 1 | 2 5 2 | 1 4 4 7 3 | 0 2 3 5 8 8 4 | 1 3 7 5 | 2 6 Key: 1 | 2 = 12
Read across a row to recover the values: 3 | 0 2 3 5 8 8 is 30, 32, 33, 35, 38 and 38. Turned on its side, the plot is a histogram with bins ten points wide — but unlike a histogram it keeps every value, so you can read off the minimum (12), the maximum (56) and the median. With 17 values the median is the 9th from either end, 33.
Split Stems and Back-to-Back Plots
When most of the leaves pile onto a few stems, split each stem in two: the first line takes leaves 0–4 and the second leaves 5–9. The same scores with split stems:
Split stems
Stem | Leaf 1 | 2 1 | 5 2 | 1 4 4 2 | 7 3 | 0 2 3 3 | 5 8 8 4 | 1 3 4 | 7 5 | 2 5 | 6
A back-to-back plot compares two data sets on shared stems. The first set's leaves are written to the left of the stems, increasing away from them, so both sides read outward from the middle:
Back to back
Class A | Stem | Class B
5 2 | 1 | 8
7 4 4 1 | 2 | 2 5 6 9
8 8 5 3 2 0 | 3 | 1 4 4 6 9
7 3 1 | 4 | 0 2 4 5 8
6 2 | 5 | 1 3
Key: 2 | 1 = 12 in Class A; 1 | 8 = 18 in Class BDecimals and Negative Numbers
Decimals work the same way once you choose the leaf's place value. With stems as ones and leaves as tenths, 3.2 is 3 | 2. A value with more digits than the leaf can hold is cut off by default — 3.78 is plotted as 3 | 7 — the convention Tukey used; choose Round and it is plotted as 3 | 8. Whichever you choose, say so in the key or the figure note. For 3.2, 3.78, 4.1, 4.15 and 5.06:
Cut off (truncate)
Stem | Leaf 3 | 2 7 4 | 1 1 5 | 0 Key: 3 | 2 = 3.2
Round
Stem | Leaf 3 | 2 8 4 | 1 2 5 | 1 Key: 3 | 2 = 3.2
Negative values get their own stems. −4 is written −0 | 4: its tens digit is zero, but it is negative, so it belongs on a stem of its own, −0, just above 0. On every stem the leaves increase moving away from the stem, so −2 | 1 3 8 means −21, −23 and −28. Textbooks differ on this last detail, and the tool states its convention under the plot. For −28, −23, −21, −4, 3 and 12:
Negative values
Stem | Leaf −2 | 1 3 8 −1 | −0 | 4 0 | 3 1 | 2 Key: −2 | 1 = −21
Notice the empty −1 stem. Stems with no leaves stay in the plot, because a gap in the data is part of its shape.
Frequently Asked Questions
- How do you make a stem-and-leaf plot?
- Order the data, decide what the stems and leaves stand for (usually tens and ones), and write each stem once in a column from smallest to largest, including any stems with no data. Then write each value's last digit as a leaf beside its stem, in increasing order, and add a key such as 3 | 7 = 37. This tool does every step and shows the ordered data so you can check the plot by hand.
- What is the key in a stem-and-leaf plot?
- The key tells the reader what one stem and leaf stand for, since 3 | 7 could mean 37, 3.7 or 370. Write it with a real value from the plot — Key: 3 | 7 = 3.7 means the stems are ones and the leaves are tenths. A back-to-back plot needs one example for each side.
- How do you make a stem-and-leaf plot with decimals?
- Choose the place value of the leaf. For data such as 3.2, 4.5 and 6.7, make the stems ones and the leaves tenths, so 4.5 is 4 | 5 and the key reads 4 | 5 = 4.5. If some values have more decimal places than the leaf, cut off or round the extra digits and say which you did.
- What is a split stem-and-leaf plot?
- A plot in which every stem appears twice: the first line holds leaves 0 to 4 and the second leaves 5 to 9. Splitting doubles the number of rows, which spreads out data that would otherwise crowd onto three or four long stems and shows its shape more clearly.
- How do you read a back-to-back stem-and-leaf plot?
- The stems run down the middle and each data set's leaves run outward from them — the left set's leaves read right to left. On the row 7 4 4 1 | 2 | 2 5 6 9, the left set has 21, 24, 24 and 27, and the right set has 22, 25, 26 and 29. Comparing the lengths of the two sides row by row shows where each set is concentrated.
- How do you find the median from a stem-and-leaf plot?
- Count the leaves to get n, then count leaves from the smallest value until you reach position (n + 1) ÷ 2. With 17 values the median is the 9th; with an even number, average the two middle values. Because the leaves are in order, the plot doubles as an ordered list.