r_nacnt(C;S)

Returns the number of columns that have N/A values across a given set of columns.

Function type

Vector only

Syntax

r_nacnt(C;S)

Input

Argument Type Description
C any A space- or comma-separated list of column names

C may also be a string expression (in single quotes) constituting a pattern for matching columns. For instance, 'foo*' specifies all columns that begin with "foo".

If C is omitted, the values in all of the columns are included.

S integer A boolean column or an expression in rcv_/rcn_/rct_ which determines whether or not that column is selected to be included in the calculation. See System variables for more information about rcv_/rcn_/rct_.

If S is omitted, all columns will be considered by the function (subject to any prior column selections).

Return Value

For each row of the table, r_nacnt returns an integer value corresponding to the number of columns in C that have N/A values.
Note: For columns containing text values, an empty string is not considered an N/A value, and is therefore not counted by r_nacnt.