View source: R/returnStateEvents.R
returnStateEvents | R Documentation |
Given a data.table updated with stop and move events from
stopFinder
, returns data aggregated to the event level.
returnStateEvents(dt)
dt |
data.table updated with stop and move events from
|
data.table with one line per stop/move event, annotated with columns state_id, state, begin_time, end_time and n_locations. Move events contain information on the raw_travel_dist and a move_id. Stop events have values for columns meanlat and meanlon, which are respectively the mean latitude and longitude of locations occurring during the stop.
library(data.table)
data(loc_data_2019); setDT(loc_data_2019)
stopFinder(loc_data_2019, thetaD = 200, thetaT = 300)
returnStateEvents(loc_data_2019)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.