Description 
HISTCND Histogram count for n dimensional data.
N = HISTCND(X,EDGES), for row vectors X, counts the number of values in
X that fall between the grid defined by the cell array of EDGES, each
of whose element is a vector that contain monotonically nondecreasing
values. N is an ND array each of whose dimension corresponds to
LENGTH(EDGES{j}) and each element contains a count of data that falls
into the edge.
X is NbyD matrix representing N data points in D dimensional space.
EDGES must have the same length to the number of columns of X.
Alternatively, EDGES can be a numeric vector which gives a uniform
grid for all dimensions of X.
N(k1,k2,...) will count the vector X(i,:) if for each dimension
j = 1,2,..., EDGES{j}(kj) <= X(i,j) < EDGES{j}(kj+1). The last bin will
count any values of X that match EDGES(end). Values outside the values
in EDGES are not counted. Use inf and inf in EDGES to include all
nonNaN values.
[N,BIN] = HISTCND(X,EDGES) also returns subscript indices BIN.
BIN is zero for out of range values.
Example:
>> X = randn(100,2); % 100by2 row vectors
>> edges = {2:.4:2,2:.5:2}; % ranges for each dimension
>> histcnd(X,edges)
ans =
0 0 0 1 1 1 0 0 0
0 1 1 2 1 1 0 0 0
1 0 3 4 0 3 0 0 0
0 1 2 1 3 0 1 0 0
0 3 1 4 2 1 3 1 0
1 1 2 3 3 4 1 0 0
0 1 1 2 1 1 4 0 0
0 1 2 2 2 1 0 0 0
1 2 0 3 2 0 0 1 0
0 1 1 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0
