Topic: DMD0093 COUNTIF - Count If |
|
This instruction can only be used in the Expression parameter of the Calculate Expression (MATH) instruction.
The Count If (COUNTIFxx) math functions count the number of locations in the specified range that match the specified value by making the comparison by the function name. There are six variants of the CountIf math function, and all six have the following three parameters:
The
first parameter specifies the
comparison value. This can be any expression parameter, including any
constant value, any readable numeric location, any readable bit location,
any Math function, or any combination of these with Math operators. The
second parameter specifies the
first location in the range of locations to compare against. This can
be any readable numeric data-block location, or any readable bit data-block
location. The third parameter specifies the number of contiguous locations that will be compared against. This can be any expression parameter, including any constant value, any readable numeric location, any readable bit location, any Math function, or any combination of these with Math operators.
|
|
The following are the 6 variants of the Count If math function:
|
|
See Also:
COUNTIF - Count If
|
|
Rung Example:
|
|