dateCheck {ensembleBMA} | R Documentation |
Checks date format.
Description
Checks that the character form of a vector of dates conforms to YYYYMMDDHH or YYYYMMDD.
Usage
dateCheck(YYYYMMDDHH)
Arguments
YYYYMMDDHH |
A character vector (or its factor equivalent) of dates which should be in the form YYYYMMDDHH or YYYYMMDD, in which YYYY specifies the year, MM the month, DD the day, and (optionally) HH the hour. |
Details
If both YYYYMMDDHH and YYYYMMDD are present,
the YYYYMMDD dates are assumed to be in error
even if HH == 00 for all of the longer dates.
Requires the chron
library.
Value
A logical vector indicating whether or not each element of YYYYMMDDHH has the correct format.
See Also
Examples
dateCheck(c("2008043000", "20080431", "20080501"))
[Package ensembleBMA version 5.1.8 Index]