R/is.ISO8601.R

Defines functions is.ISO8601

Documented in is.ISO8601

is.ISO8601 = function(x) {
  is.ISO = FALSE
  if (is.character(x)) {
    NNeg = length(unlist(strsplit(x,"[-]")))
    NPos = length(unlist(strsplit(x,"[+]")))
    if (NPos == 2 | NNeg == 4 | NNeg == 2) {
      is.ISO = TRUE
    }
  }
  return(is.ISO)
}

Try the GGIR package in your browser

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

GGIR documentation built on Oct. 17, 2023, 1:12 a.m.