Learn R Programming

fame (version 1.13)

as.Date.jul: Convert ti or jul objects to Dates

Description

Methods to convert ti and jul objects to class "Date" representing calendar dates.

Usage

## S3 method for class 'ti':
as.Date(x, \dots)
## S3 method for class 'jul':
as.Date(x, \dots)

Arguments

x
A ti or jul object to be converted.
...
Ignored.

Value

  • An object of class "Date".

See Also

as.Date for the generic function, Date for details of the date class.

Examples

Run this code
as.Date(today())          ## invokes as.Date.ti
as.Date(jul(today() - 7)) ## a week ago, uses as.Date.jul

Run the code above in your browser using DataLab