R/step_calculation.R
make_step_geom.Rd
This calculates step geometries as individual line segments based on the active_group
make_step_geom(group, time, geometry)
group | a c_grouping object |
---|---|
time | sft_timestamp class with start and end date |
geometry | the geometery data from either sf or sf_track. Must be an sf geometry class |
library("sf") geom <- st_as_sf(data.frame( x = c(1, 2, 2, 5), y = c(0, 1, 5, 7) ), coords = c("x", "y")) group <- list(id = rep(1, 4)) time <- 1:4 cg <- make_c_grouping(group) make_step_geom( group = cg, geometry = geom$geometry, time = time )#> Geometry set for 4 features #> Geometry type: GEOMETRY #> Dimension: XY #> Bounding box: xmin: 1 ymin: 0 xmax: 5 ymax: 7 #> CRS: NA#>#>#>#>