N missing, N nonmissing, and N total functions

To use this function, choose Calc > Calculator.

The number of missing values, nonmissing values, and total observations in a column of a worksheet.
  • N missing is the number of cells that contain the missing value symbol *.
  • N nonmissing is the number of cells that contain actual data.
  • N total is the sum of these two statistics, or the total number of observations in a column.

Syntax

Function Syntax
N missing for a column NMISS(number)
N nonmissing for a column N(number)
N total for a column COUNT(number)
N missing for a row RNMISS(number,number,...)
N nonmissing for a row RN(number,number,...)
N total for a row RCOUNT(number,number,...)

For number, specify the column number or numbers; or for row statistics, specify each column number to define the length of the rows.

Examples

Column Calculator expression Result
C1 contains *, 3, *, 7 NMISS(C1) 2
C1 contains *, 3, 4, *, 5 N(C1) 3
C1 contains 6, 3, *, 12 COUNT(C1) 4
C1 contains *, C2 contains 3, contains *, and C4 contains 7 RNMISS(C1,C2,C3,C4) 2
C1 contains *, C2 contains 4, C3 contains *, and C4 contains 5 RN(C1,C2,C3,C4) 3
C1 contains 6, C2 contains 3, C3 contains *, and C4 contains 12 RCOUNT(C1,C2,C3,C4) 4
By using this site you agree to the use of cookies for analytics and personalized content.  Read our policy