I have an histogram like this:

Where my data are stored with an append in that way:
(while parsing the file)
{
[...]
a.append(int(number))
#a = [1,1,2,1,1, ]...
}
plt.hist(a, 180)
But as you can see from the image, there are lot of blank areas, so I would like to build a barchart from this data, how can I reorganize them like:
#a = [ 1: 4023, 2: 3043, 3:...]
Where 1 is the "number" and 4023 is an example on how many "hit" of the number 1? From what I have seen in this way I can call:
plt.bar(...)
and creating it, so that I can show only the relevant numbers, with more readability. If there is a simple way to cut white area in the Histo is also welcome.
I would like also to show the top counter of each columns, but I have no idea how to do it.
