I have a pandas dataframe. The pandas dataframe has an "hours" column, which consist of only integer values from 1 to 24, but there are multiple entries for each hour. There is another column called "counts" that gives the count for each integer hour.
I would like to create a histogram plot, preferably with distplot in seaborn of the counts of each integer hour against the hour. I could sum up the counts for each distinct hour separately and then plot it, but I was wondering if there's an automatic way to do this?
For example, consider that I have two entries for hour 1, [1, 20], [1, 50]. For hour 1 on the histogram, I want it to plot 20 + 50 = 70 and not 2.