Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

which.na

Determine Which Values are Missing Values


Description

which.na returns an integer vector describing which values in the input vector, if any, are missing

Usage

which.na(x)

Arguments

x

a data object

Value

integer vector containing indices of elements in x which are missing. If there are no missing values, the functions return an integer vector of length 0 ( numeric(0)).

Author(s)

Knut M. Wittkowski kmw@rockefeller.edu

See Also

Examples

x <- c(1, 4, NA, 0, 5)
which.na(x)
# [1] 3

muStat

Prentice Rank Sum Test and McNemar Test

v1.7.0
GPL (>= 2)
Authors
Knut M. Wittkowski <kmw@rockefeller.edu> and Tingting Song <ttsong@gmail.com>
Initial release
2010-09-17

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.