Skip to content

Commit

Permalink
.
Browse files Browse the repository at this point in the history
  • Loading branch information
EhrmannS committed Sep 16, 2024
1 parent 7fe4f85 commit b4de301
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions R/helpers.R
Original file line number Diff line number Diff line change
Expand Up @@ -685,7 +685,7 @@
#' @param clusters [\code{list(7)}]\cr the cluster slot of the schema.
#' @return the columns or rows of the evaluated position
#' @importFrom checkmate assertNumeric assertList assertDataFrame
#' @importFrom rlang eval_tidy
#' @importFrom rlang eval_tidy prim_name
#' @importFrom purrr map_int map_lgl
#' @importFrom tibble rownames_to_column
#' @importFrom tidyr pivot_longer pivot_wider
Expand Down Expand Up @@ -732,7 +732,11 @@
mutate(across(.cols = where(function(x) suppressWarnings(!anyNA(as.numeric(x[!is.na(x)]))) & !all(is.na(x))), .fns = as.numeric))

cols <- map_int(.x = 1:dim(input)[2], .f = function(ix){
map(subset[,ix], term)[[1]] & !all(is.na(subset[,ix]))
if(prim_name(term) != "is.na"){
map(subset[,ix], term)[[1]] & !all(is.na(subset[,ix]))
} else {
map(subset[,ix], term)[[1]]
}
})

} else {
Expand Down

0 comments on commit b4de301

Please sign in to comment.