Reads a CSV file defining coarse stationary periods (stap0) or validates a data.frame,
including date parsing, ordering, and overlap checks.
Usage
read_stap(x, required_cols = c("start", "end"))See also
Other tag:
print.tag(),
tag_create(),
tag_set_map(),
tag_stap_daily()
Examples
# From a data.frame
stap_df <- data.frame(
start = as.POSIXct(c("2020-01-01", "2020-01-03"), tz = "UTC"),
end = as.POSIXct(c("2020-01-02", "2020-01-04"), tz = "UTC")
)
read_stap(stap_df)
#> start end
#> 1 2020-01-01 2020-01-02
#> 2 2020-01-03 2020-01-04
# From a CSV path
# read_stap("./data/stap-label/18LX.csv")
