R/which_NA.R

Defines functions which_notNA which_NA

which_NA <- function(x) {
  ans <- .Call("Cwhich_isna", x, FALSE, 1L, PACKAGE = packageName)
  if (is.null(ans)) {
    return(seq_along(x))
  }
  ans
}

which_notNA <- function(x) {
  ans <- .Call("Cwhich_isna", x, TRUE, 1L, PACKAGE = packageName)
  if (is.null(ans)) {
    return(seq_along(x))
  }
  ans
}

Try the hutilscpp package in your browser

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

hutilscpp documentation built on Oct. 11, 2023, 9:06 a.m.