Documentation

Tests if any of the elements are true. More...

## Modules

anytrue
The C++ interface for anytrue.

af_anytrue
the C interface for anytrue

## Detailed Description

Tests if any of the elements are true.

Verify if any of the elements are non zero.

These functions can also be used with conditions as parameters.
In such a case, the input array to the function is a boolean array.

bool hx[] = { true,true,false,true };
array x1(4,1, hx); // 4x1 vector
printf("%d,%d\n", anytrue<bool>(x1))// 0,0
array y1 = randu(100, 1);
array y2 = anytrue(y1 > 0.5); // y2 is 1 where all values in the
// dimension are true, otherwise 0.