Histogram.
N = nan_hist(Y) N = nan_hist(Y,M) N = nan_hist(Y,X) nan_hist(...,'plot') produces a histogram bar plot of the results. nan_hist(AX,...) plots into AX instead of GCA. [N,X] = nan_hist(...)
input vector or matrix. If Y is a matrix, hist works down the columns.
number of equally spaced containers in which Y is sorted [default: 10]
X is a vector which specifies centers of each container. The first bin includes data between -inf and the first center and the last bin includes data between the last bin and inf. Note: Use HISTC if
number of elements in each container
position of the bin centers in X.
x = -4:0.1:4; y = rand(10000,1,'normal'); nan_hist(y,x,'plot')