remove_incomplete_strata: Remove strata with missing values for observed steps
Description
Remove strata with missing values for observed steps
Usage
remove_incomplete_strata(x, ...)
# S3 method for random_steps
remove_incomplete_strata(x, col = "ta_", ...)
Value
An object of class random_steps, where observed steps (case_ == TRUE) with missing values (NA) in the column col are removed (including all random steps).
Arguments
x
An object of class random_steps.
...
Further arguments, none implemented.
col
A character with the column name that will be scanned for missing values.
mini_deer <- deer[1:4, ]
# The first step is removed, because we have `NA` turn angles.mini_deer |> steps() |> random_steps() |> remove_incomplete_strata() |>
select(case_, ta_, step_id_)