R/nr_to_na.R

Defines functions nr_to_na

Documented in nr_to_na

#' Convert NR (Not Recorded) to NA (Not Available)
#'
#' This function converts the \code{'NR'} string to \code{NA}.
#'
#' @param x a character vector.
#'
#' @return a character vector whose \code{'NR'} have been replaced with
#'   \code{NA}.
#'
#' @keywords internal
nr_to_na <- function(x) {

  x[x == 'NR'] <- NA_character_
  x
}

Try the quincunx package in your browser

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

quincunx documentation built on July 9, 2023, 7:32 p.m.