View source: R/convert_date_to_numeric.R
max_cycle_length | R Documentation |
This function returns the maximum possible value that a specific time component can take, given a cycle length and scale.
max_cycle_length(cycle_length, time_scale)
cycle_length |
A character string indicating the larger unit of time. It must be one of "year", "month", "day", "hour", "minute". |
time_scale |
A character string indicating the smaller unit of time,
which is a division of the |
The function returns the maximum possible value that the time_scale
can take within one cycle_length
.
max_cycle_length("year", "month") # Maximum months is a year 12
max_cycle_length("day", "minute") # Maximum minutes in a day 1440
max_cycle_length("year", "day") # Maximum days in a year 366
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.