dropAllNA: Takes an array and return a copy without cols/rows that are...

Description Usage Arguments Value Examples

View source: R/transform.R

Description

Takes an array and return a copy without cols/rows that are NAs-only

Usage

1
dropAllNA(data, mar = 1, id = NULL)

Arguments

data

matrix or data.frame

mar

margin (1 for rows, 2 for columns)

id

a character vecor with column names that are id/keys and should by skipped when testing for missingness

Value

an array of the same type as the input data object.

Examples

1
2
3
4
tmp <- data.frame(a = 1:5, b = c(34, 45, 56, NA, NA), c = c(2, 3, 4, 5, NA))
deleteAllNA(tmp)
deleteAllNA(tmp, id = "a")
deleteAllNA(tmp, id = c("a", "b"))

vh-d/VHtools documentation built on May 3, 2019, 6:11 p.m.