na: Gives summary information on NA values

Description Usage Arguments Value Examples

View source: R/na.R

Description

Given an object, prints out a summary table describing the number and percent of missing data (NAs), both overall and by column (for data.frames, matricies) or element (for lists).

Usage

1
na(.data, ...)

Arguments

.data

a data.frame, data.table, matrix, list, or vector

...

Specification of columns to fill, leaving blank will select all columns. Use bare variable names. Select all variables between x and z with x:z, exclude y with -y. For more options, see the dplyr::select documentation. For lists, elements are treated as columns.

.dots

Use na_() to do standard evaluation. See dplyr's NSE vignette for more information with vignette("nse", "dplyr").

Value

a table detailing the NAs in an object

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
Examining the NAs in a data.frame
na(mtcars)

The \code{na} function also works on vectors:
na(LETTERS)

Matricies:
na(as.matrix(mtcars))

and Lists:
na(as.list(mtcars))

jakesherman/missr documentation built on May 18, 2019, 9:08 a.m.