Question
What is the difference between a bar graph and a histogram? When do we use each?
Solution — Step by Step
A bar graph (or bar chart) represents categorical or discrete data — data that fits into distinct, separate groups. Each bar represents one category.
A histogram represents continuous data — data that is measured on a continuous scale and grouped into class intervals (ranges). Each bar represents a class interval.
The fundamental difference: bar graphs are for categories, histograms are for continuous numeric ranges.
The most visible difference: histograms have no gaps between bars; bar graphs have gaps.
In a histogram, the bars touch because the data is continuous — there’s no gap between 10–20 and 20–30 (20 belongs to one of them). In a bar graph, bars are separated because categories are distinct (apples and oranges don’t blend into each other).
Also, in a histogram, the x-axis shows numerical ranges (class intervals), while in a bar graph the x-axis shows category names.
In a bar graph: the height of each bar = the frequency (or value) of that category. Width has no meaning.
In a histogram: the area of each bar is proportional to frequency, not just the height. This matters when class intervals have unequal widths. We use frequency density on the y-axis:
For equal class widths (most school problems), height directly represents frequency — but the principle of area remains important.
| Feature | Bar Graph | Histogram |
|---|---|---|
| Data type | Categorical or discrete | Continuous (grouped) |
| X-axis | Categories (names) | Class intervals (numbers) |
| Gaps between bars | Yes (bars separated) | No (bars touch) |
| Bar width | Uniform (no meaning) | Represents class width |
| Bar height represents | Frequency/value | Frequency density (for unequal widths) |
| Can reorder bars? | Yes | No (intervals have natural order) |
| Example data | Favourite subject of students | Heights of 50 students |
Why This Works
The gap/no-gap rule isn’t arbitrary — it reflects the nature of the data. Continuous data has no natural breaks: a student 159 cm tall is not categorically different from one who is 160 cm. The histogram reflects this continuity by having touching bars.
Categorical data has genuine breaks: “Science” and “Maths” are genuinely separate categories with no in-between. The gap between bar graph bars reflects this separation.
Alternative Method — Ask Two Questions
When deciding which graph to use:
- Is the data measured on a number line (height, weight, temperature, marks)? → Histogram
- Are you counting occurrences in named categories (colours, subjects, cities)? → Bar Graph
Common Mistake
Drawing gaps between bars in a histogram. This is the single most common error in CBSE exams. A histogram with gaps looks like a bar graph and loses marks. Remember: histogram bars always touch because the class intervals are continuous and adjacent.
A frequency polygon is drawn by joining the midpoints of the tops of histogram bars. It’s a useful transformation of a histogram — worth knowing as it often appears in the same question as histograms in Class 9–10 boards.