## Format is valid, date/datetimes are real
is_valid_dtc("2020-02")
is_valid_dtc("2020-02-28")
is_valid_dtc("2020-02-28T14:43")
# Format is valid, date/datetimes are not real but this is not checked
is_valid_dtc("2020-02-31")
is_valid_dtc("2020-02-28T25:00:00")
# Format is valid, date/datetimes are not real and this is checked
is_valid_dtc("2020-02-31", check_dtc = TRUE)
is_valid_dtc("2020-02-28T25:00:00", check_dtc = TRUE)
Run the code above in your browser using DataLab