Histogram: How Bin Width Shapes the Story
April 12, 2026
Problem
Show how changing the bin width of a histogram dramatically changes the visual shape of the same dataset.
Explanation
What is a histogram?
A histogram groups continuous data into intervals (bins) and shows the frequency (count) of values in each bin as a bar. Unlike a bar chart, the bars touch — the x-axis is a continuous number line.
How bin width changes the story
The same data can tell very different visual stories depending on the bin width:
- Too few bins (wide): The histogram looks like 2-3 big blocks. It hides the shape of the distribution — you can't see if it's bimodal, skewed, or normal.
- Too many bins (narrow): Each bar is very short and jagged. Noise overwhelms the pattern — you see random spikes, not the underlying distribution.
- Just right: The shape of the distribution is clear — you can see peaks, symmetry, skewness, and gaps.
Rules of thumb for choosing bin count
- Square root rule: (for : about 14 bins).
- Sturges' formula: (for : about 9 bins).
- Freedman-Diaconis: bin width (accounts for data spread).
Histogram vs bar chart
- Histogram: continuous data, bars touch, order matters (x-axis is numerical).
- Bar chart: categorical data, bars separated, order is flexible.
Try it in the visualization
Drag the bin width slider. Watch the same data reshape dramatically. Too wide hides bimodality; too narrow shows noise. The "just right" zone reveals the true distribution shape.
Interactive Visualization
Parameters
5.00
200.00
Normal
1.00
Your turn
Got your own math or physics problem?
Turn any problem into an interactive visualization like this one — powered by AI, generated in seconds. Free to try, no credit card required.
Sign Up Free to Try It30 free visualizations every day