matplotlib.pyplot.hist( )
matplotlib.pyplot.hist(x, bins=None, range=None, density=None, weights=None, cumulative=False, bottom=None, histtype=’bar’, align=’mid’, orientation=’vertical’, rwidth=None, log=False, color=None, label=None,
stacked=False, normed=None, hold=None, data=None, **kwargs)
- Compute and draw the histogram of x. The return value is a tuple (n, bins, patches) or ([n0, n1, …],
- bins,[integer or sequence or ’auto’, optional] If an integer is given, bins + 1 bin edges are calculated and returned, consistent with numpy.histogram().
If bins is a sequence, gives bin edges, including left edge of first bin and right
edge of last bin. In this case, bins is returned unmodified.
All but the last (righthand-most) bin is half-open. In other words, if bins is:
[1, 2, 3, 4] then the first bin is [1, 2) (including 1, but excluding 2) and the second [2, 3).
The last bin, however, is [3, 4], which includes 4.
Unequally spaced bins are supported if bins is a sequence.
If Numpy 1.11 is installed, may also be ’auto’.
Default is taken from the rcParam hist.bins - range [tuple or N