This method ensure keeping the cropr_simulation
attribute when subsetting a
cropr_simulation
list.
# S3 method for class 'cropr_simulation'
x[...]
A subset of a cropr_simulation
, keeping its attribute
path <- file.path(get_examples_path("sti"), "workspace1")
sim <- SticsRFiles::get_sim(workspace = path)
#> mod_spintercrop_pea_barley.stimod_saintercrop_pea_barley.sti
#> mod_sgrass.sti
#> mod_smaize.sti
# sim returns a `cropr_simulation` list