| reshape_adates | R Documentation |
Re-arranges full and partial dates in the general form of "MM/DD/YYYY" to
the ISO 8601 format ("YYYY-MM-DD"). This function is appropriate for
vectors with mixed full and partial dates because it will not convert the
partial dates to NA which would occur if you used
as.Date("02/UN/2017", format = "%m/%d/%Y").
reshape_adates(dates)
dates |
a character vector of full and/or partial dates |
The date component separator in the input vector dates can be any
character.
a character vector of full and/or partial dates in the format
"YYYY-MM-DD"
reshape_pdates(), impute_pdates(), trim_dates(),
vignette("Dates")
dates <- c("02/05/2017", "UN/UN/2017", "02-05-2017", NA)
reshape_adates(dates)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.