| set_day_part {when} | R Documentation |
Set day part
Description
Using this function we can change the name assigned to the hours of the day to designate the parts of the day.
Usage
set_day_part(td, hour, name)
## S3 method for class 'when'
set_day_part(td, hour = NULL, name = NULL)
Arguments
td |
A |
hour |
A number, hour number (between 0 and 23). |
name |
a string, name of the part of the day. |
Value
A when object.
See Also
Other dimension definition:
define_characteristics(),
define_instances(),
get_attribute_definition_function(),
get_day_part(),
get_week_date_range(),
select_date_levels(),
select_day_level(),
select_month_level(),
select_quarter_level(),
select_semester_level(),
select_time_level(),
select_week_level(),
select_year_level(),
set_attribute_definition_function(),
when()
Examples
td <- when() |>
set_day_part(hour = c(21:23, 0:4), name = "Night")
[Package when version 1.0.0 Index]