Skip to contents

Compares observed and simulated path structure using the straightness index, defined as net displacement divided by total path length. Low values indicate more tortuous trajectories.

Usage

validate_sinuosity(observed, simulated, ...)

Arguments

observed

Observed track-like object.

simulated

A list of simulated track-like objects or a data frame with a simulation identifier column.

...

Passed to as_gmov_simulations().

Value

A list with observed and simulated straightness indices, discrepancy statistics, and a Monte Carlo rank test.

References

Benhamou, S. (2004). How to reliably estimate the tortuosity of an animal's path. Journal of Theoretical Biology, 229(2), 209-220. https://doi.org/10.1016/j.jtbi.2004.03.016

Nicosia, A. (2026). Beyond the next step: A multi-criteria generative validation framework for step selection functions. Methods in Ecology and Evolution. https://doi.org/10.1111/2041-210x.70313

Examples

observed <- data.frame(x = c(0, 1, 1), y = c(0, 0, 1))
simulated <- list(
  data.frame(x = c(0, 1, 2), y = c(0, 0, 0)),
  data.frame(x = c(0, 0, 1), y = c(0, 1, 1))
)
validate_sinuosity(observed, simulated)
#> gmov sinuosity diagnostic
#> Measure: straightness_index 
#> Simulated tracks: 2 
#> Observed value: 0.7071 
#> Discrepancy statistic: 0.1464 
#> Monte Carlo p-value: 1.000 
#> Alternative: greater