This calculates step geometries as individual line segments based on the active_group

make_step_geom(group, time_data, geometry)

Arguments

group

a c_grouping object

time_data

time vector

geometry

the geometery data from either sf or sf_track. Must be an sf geometry class

Examples

#'
library("sf")
geom <- st_as_sf(data.frame(
  x = c(1, 2, 2, 5),
  y = c(0, 1, 5, 7)
), coords = c("x", "y"))

burst <- list(id = rep(1, 4))
time <- 1:4

cg <- make_c_grouping(burst)

make_step_geom(
  group = cg,
  geometry = geom$geometry,
  time_data = time
)
#> Geometry set for 4 features 
#> Geometry type: GEOMETRY
#> Dimension:     XY
#> Bounding box:  xmin: 1 ymin: 0 xmax: 5 ymax: 7
#> CRS:           NA
#> LINESTRING (1 0, 2 1)
#> LINESTRING (2 1, 2 5)
#> LINESTRING (2 5, 5 7)
#> POINT (5 7)