Convert an object to a period
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 | as_period(x, interval, firstdate, ...)
## Default S3 method:
as_period(x, interval, firstdate, ...)
## S3 method for class 'period'
as_period(x, interval = 1L, firstdate = NULL, ...)
## S3 method for class 'Date'
as_period(x, interval = 1L, firstdate = NULL, ...)
## S3 method for class 'POSIXt'
as_period(x, interval = 1L, firstdate = NULL, ...)
## S3 method for class 'character'
as_period(x, interval = 1L, firstdate = NULL, ...)
## S3 method for class 'factor'
as_period(x, interval = 1L, firstdate = NULL, ...)
|
x |
'An object to coerce to period. |
interval |
How many days to include in each period. |
firstdate |
The date to firstdate the intervals from. If NULL (default) the earliest date in the vector will be used. |
... |
Not used. |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.