Map and Table Calculation
CNT( ) function
Counts the number of times that values in a column are not undefined.
Syntax
CNT(Column)
Input
Output
Notes:
- The CNT function can only be used on the command line of a table window; it cannot be used on the command line of the Main window.
- The CNT function can also be performed through
a dialog box, see Column
Statistics.
- When a value in the input column is undefined, the value is excluded from the calculation.
Tips:
- Use the AGGCNT function to count the number of times that Column is not undefined, or the number of times that Column is not undefined per group.
- When the definition symbol = is used, a dependent output column is created; when the assignment symbol := is used, the dependency link is immediately broken after the output column has been calculated.
Usable in
TabCalc, Simple calculators
Examples
Pocket line calculator example:
? CNT(InCol) |
returns 8.000 |
TabCalc example:
OutCol = CNT(InCol)
InCol |
OutCol |
-5 |
8 |
-2 |
8 |
-1 |
8 |
0 |
8 |
? |
8 |
4 |
8 |
8 |
8 |
9 |
8 |
11 |
8 |
See also: