Skip to contents

new_event_time() is the low-level constructor behind event_time(). It only checks the types of its arguments, not their values, so it's for code that has already validated them.

Usage

new_event_time(time = list(), status = character())

Arguments

time

A list with one numeric vector per element: the time (length one), or the lower and upper bounds of an interval (length two).

status

A character vector of status codes, the same length as time.

Value

An event_time vector.

See also

event_time(), which checks its input.

Examples

new_event_time(time = list(7, c(2, 4)), status = c("e", "i"))
#> <event_time[2]>
#> [1] 7      [2, 4]