naInContext: Display Missing Values in Context

Description Usage Arguments Details Value Author(s) References Examples

Description

Display rows of data with missing values, as well as other rows with the same key.

Usage

1
naInContext(x, context, search)

Arguments

x

data.frame.

context

character vector of column names representing a key

search

character vector of column names representing search fields.

Details

Often one wants to view not just records with missing values, but other related records as well, e.g. “view all the records for any subject with missing doses”. naInContext searches for NAs in columns of x named by search. It then determines keys for these rows, using columns in x named by context. Finally, it displays all rows with matching keys.

Value

data.frame

Author(s)

Tim Bergsma

References

http://metrumrg.googlecode.com

Examples

1
2
3
test <- Theoph
test$conc[[5]] <- NA
naInContext(test, context='Subject', search='conc')

metrumrg documentation built on May 2, 2019, 5:55 p.m.