Converts simulated trajectories to a named list of gmov tracks. The preferred
input is a list of track-like objects. A single data frame can also be used
if it contains a simulation identifier column. This covers common simulated
track outputs and data-frame-like objects following amt coordinate
conventions, but it is not a wrapper around amt simulation internals.
Arguments
- simulated
A list of track-like objects, or a data frame containing multiple tracks.
- id_col
Optional character name of the simulation identifier column when
simulatedis a data frame. If omitted, gmov looks for common simulation columns such assim_id,sim_id_,.simulation,simulation,.replicate, orreplicate.- ...
Passed to
as_gmov_track().
Examples
sims <- list(
data.frame(x = c(0, 1), y = c(0, 0)),
data.frame(x = c(0, 0), y = c(0, 1))
)
as_gmov_simulations(sims)
#> $sim_1
#> # A tibble: 2 × 4
#> x y x_ y_
#> <dbl> <dbl> <dbl> <dbl>
#> 1 0 0 0 0
#> 2 1 0 1 0
#>
#> $sim_2
#> # A tibble: 2 × 4
#> x y x_ y_
#> <dbl> <dbl> <dbl> <dbl>
#> 1 0 0 0 0
#> 2 0 1 0 1
#>
#> attr(,"class")
#> [1] "gmov_simulations" "list"