any

Type: External

Group: matrix

Syntax

answer = any(matrix)

Description

Returns 1 if any of the elements of the supplied matrix are not zero.

Examples

any([0,0;0,0]) = 0
any([1,0;0,0]) = 1

See Also

and, eye, all