Histograms plot how often different numbers appear in a distribution using bars. They are often used to visualize distributions like the normal distribution.
Often in numeric datasets, each number might only occur once, but similar numbers might show up a lot. For example, we might have points for 1.01, 1.02, and 1.00. These numbers are all very close, but not exactly the same.
Histograms group similar numbers together in bins. Each bin has a width, e.g. 0.1. Most histograms have a fixed bin width. Some histograms, like exponential histograms, have a variable bin width that makes it easy to visualize distributions with a long tail.
The height of each bar on the histogram is controlled by how many numbers are within each bin. The bar width represents how big the range of values in the bin is.
Histograms are really useful for visualizing distributions of data. For example, you might want to know how much rain your city gets. The mean gives you an average, but it does not tell you if there is a lot of rain on a few days per year, or if there is a little bit of rain every day. A histogram will show you whether there are a few days with a lot of rain or a lot of days with a little rain.