Date-getters | R Documentation |
These are Date methods for the getter generics.
get_year()
returns the Gregorian year.
get_month()
returns the month of the year.
get_day()
returns the day of the month.
For more advanced component extraction, convert to the calendar type that you are interested in.
## S3 method for class 'Date'
get_year(x)
## S3 method for class 'Date'
get_month(x)
## S3 method for class 'Date'
get_day(x)
x |
A Date to get the component from. |
The component.
x <- as.Date("2019-01-01") + 0:5
get_day(x)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.