diff --git a/R/add_path.R b/R/add_path.R index 5f5e379..9e8e9e1 100644 --- a/R/add_path.R +++ b/R/add_path.R @@ -217,6 +217,9 @@ add_path_subdata <- function(subdata, cutoff) { subdata_path <- lapply(subdata_moves, check_moves, cutoff = cutoff) subdata <- dplyr::bind_rows(subdata_path) + if (nrow(subdata) != 0) { + subdata$path <- as.factor(subdata$path) + } subdata }