Skip to content

Commit

Permalink
#40 update fn to correctly subset for collinearity analysis
Browse files Browse the repository at this point in the history
  • Loading branch information
egouldo committed Jun 14, 2024
1 parent 5fed3a9 commit 3e00769
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion R/generate_collinearity_subset.R
Original file line number Diff line number Diff line change
Expand Up @@ -53,10 +53,13 @@ generate_collinearity_subset <- function(ManyEcoEvo, collinearity_subset) {
mutate(data = map(.x = data,
.f = dplyr::anti_join, collinearity_subset,
by = join_by(response_id, id_col, dataset) )) %>%
mutate(effects_analysis = map(.x = effects_analysis,
.f = dplyr::anti_join, collinearity_subset,
by = join_by(response_id, study_id == id_col, dataset) )) %>%
mutate(diversity_data =
map2(.x = diversity_data,
.y = data,
.f = ~ semi_join(.x, .y) %>% distinct),
.f = ~ semi_join(.x, .y, join_by(id_col, dataset)) %>% distinct),
collinearity_subset = "collinearity_removed")

out <- bind_rows(
Expand Down

0 comments on commit 3e00769

Please sign in to comment.