Given a data frame as input the function will calculate the clusters.
Usage
extract_event_periods(df, min_length = 10)
Arguments
- df
a dataframe containing columns of data, with timestamp in either date, datetime, or dttm format.
- min_length
minimum length of the event
Value
Returns a df of events with the columns `start` and `end` date (or datetime).
Examples
if (FALSE) { # \dontrun{
extract_event_periods(
sonde_data %>%
rename(timestamp=TIMESTAMP,flag=event_flag),
min_length=50)
} # }