R/H-prevYear.R

prevYear <- function(dateObject, prevMonth){
  ifelse(prevMonth=="12"
         ,as.character(lubridate::year(dateObject) - 1)
         ,as.character(lubridate::year(dateObject))
  )
}
erolbicero/tsconv documentation built on May 16, 2019, 8:49 a.m.