HIST Histogram. N = HIST(Y) bins the elements of Y into 10 equally spaced containers and returns the number of elements in each container. If Y is a matrix, HIST works down the columns. N = HIST(Y,M), where M is a scalar, uses M bins. N = HIST(Y,X), where X is a vector, returns the distribution of Y among bins with centers specified by X. Note: Use HISTC if it is more natural to specify bin edges instead. [N,X] = HIST(...) also returns the position of the bin centers in X. HIST(...) without output arguments produces a histogram bar plot of the results. See also HISTC.