missVals {CMO}R Documentation

Counts missing values within an matrix

Description

Counts missing values foreach column of a matrix

Usage

missVals(x)

Arguments

x Input matrix. Only NA is allowed as missing value entry.

Value

returns a one row matrix with the count of NAs foreach column of the input matrix

Author(s)

Christian Montel

See Also

is.na and apply

Examples

#create some data
dat <- matrix(c(1,1,1,2,NA,2,3,NA,3),nrow=3,byrow=TRUE)
dat
missVals(dat)

[Package CMO version 1.02 Index]