Description Usage Arguments Value Examples
Extract numeric months of the year from a Date, POSIXct or POSIXlt vector.
1 2 3 4 5 6 7 8 9 10 | months(date = NULL, string = TRUE, abbreviate = FALSE)
## S3 method for class 'Date'
months(date, string, abbreviate)
## S3 method for class 'POSIXct'
months(date, string, abbreviate)
## S3 method for class 'POSIXlt'
months(date, string, abbreviate)
|
date |
Date, POSIXct or POSIXlt vector |
string |
Logical, if TRUE months string is returned, otherwise numeric |
abbreviate |
logical. Should the months in string format be abbreviated? |
A vector with extracted months.
1 2 3 4 5 6 7 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.