This is driving me crazy and I'm wondering if I just don't understand something fundamental about histograms, matplotlib, or the world. If i try a plot the following data with matplotlib's histogram, i get the following image, which is definitely not correct:
import matplotlib.pyplot as plt
v = [1.25, 5.0, 2.0, 1.0, 3.25, 1.75, 0.25, 2.75, 1.25]
fig, ax = subplots()
ax.hist(v, 8, edgecolor='white')
fig.show()
1.25 seems to be correct, but for example, 5 is entirely wrong, and 1 is not plotted. Am I doing something wrong? (note: the default alignment for a matplotlib histogram is centered over the value)