Date-time must be a POSIXct, POSIXlt, Date, chron, yearmon, yearqtr, zoo, zooreg, timeDate, xts, its, ti, jul, timeSeries, and fts objects.
date(x) date(x) <- value
| x | a date-time object |
|---|---|
| value | an object for which the |
the date of x as a Date
date() does not yet support years before 0 C.E.
Also date() is not defined for Period objects.
date() can be called without any arguments to return a string representing
the current date-time. This provides compatiblity with base:date() which
it overrides.
#> [1] "2012-03-26"#> [1] "2012-03-27"#> [1] "2012-03-26"#> [1] "2000-01-02 23:12:13 EST"