For a vector argument, return 1 if any element of the vector is nonzero.
For a matrix argument, return a row vector of ones and zeros with each element indicating whether any of the elements of the corresponding column of the matrix are nonzero. For example,
any (eye (2, 4)) [ 1, 1, 0, 0 ]If the optional argument dim is supplied, work along dimension dim. For example,
any (eye (2, 4), 2) [ 1; 1 ]