R/GetHierID.R

Defines functions GetHierID

Documented in GetHierID

GetHierID <- function(MyHier){
  if(class(MyHier) == "list")
    conceptID <- gsub("^\\D+|\\D+$", "", names(MyHier))
  if(class(MyHier) == "character")
    conceptID <- gsub("^\\D+|\\D+$", "", MyHier)
  if(any(conceptID == "") || any(is.na(conceptID)))
    conceptID[which(conceptID == "")] <- NA
  return(conceptID)
}

Try the Reol package in your browser

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

Reol documentation built on May 30, 2017, 12:30 a.m.