R/nmissing.R

#' Count the number of missing values in a vector or data matrix
#' @param x a vector, matrix or data frame
#' @return the number of missing values (denoted by NA)
#' @export
#' @examples
#' data(hqmr.data)
#' nmissing(hqmr.data)
nmissing <- function(x) sum(is.na(x))

Try the cutoffR package in your browser

Any scripts or data that you put into this service are public.

cutoffR documentation built on May 2, 2019, 6:12 a.m.