R/invalid.R

# $Id: invalid.R 625 2005-06-09 14:20:30Z nj7w $

invalid <- function(x)
  {
    if( missing(x) || is.null(x) || length(x)==0 )
      return(TRUE)
    if(is.list(x))
      return(all(sapply(x,invalid)))
    else if(is.vector(x))
      return(all(is.na(x)))
    else
      return(FALSE)
  }

Try the gtools package in your browser

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

gtools documentation built on May 2, 2019, 4:52 p.m.