View source: R/date_fix_century.R
date_fix_century | R Documentation |
# fix year by assigning a date (date_ymd) above the cutoff date (cut_date_ymd) to the 1900s or below to the 2000s.
date_fix_century( date_ymd = lubridate::ymd("2020-03-26"), cut_date_ymd = lubridate::ymd(Sys.Date()) )
date_ymd |
Date to check. YMD format ("2020-03-26"). |
cut_date_ymd |
Optional. Date to check against. YMD format ("2020-03-26"). Defaults to current system date. |
date_fix_century("2049-11-30") [1] "1949-11-30"
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.