Skip to content

Commit

Permalink
ensure temp objects removed correctly
Browse files Browse the repository at this point in the history
  • Loading branch information
zdz2101 committed Jul 29, 2024
1 parent 72eeb14 commit 314c097
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion R/derive_params_growth_age.R
Original file line number Diff line number Diff line change
Expand Up @@ -374,7 +374,7 @@ derive_params_growth_age <- function(dataset,
}

dataset_final <- dataset_final %>%
select(-c(SD2pos, SD3pos, SD2neg, SD3neg, age_bins, temp_val, temp_z))
select(-c(SD2pos, SD3pos, SD2neg, SD3neg, age_bins))

return(dataset_final)
}
6 changes: 3 additions & 3 deletions R/derive_params_growth_height.R
Original file line number Diff line number Diff line change
Expand Up @@ -296,7 +296,7 @@ derive_params_growth_height <- function(dataset,
mutate(!!!set_values_to_sds)

dataset_final <- bind_rows(dataset, add_sds, unmatched_sds) %>%
select(-c(L, M, S, sex_join, heightu_join, meta_height))
select(-c(L, M, S, sex_join, heightu_join, meta_height, temp_val, temp_z))
}

if (!is_empty(set_values_to_pctl)) {
Expand Down Expand Up @@ -326,11 +326,11 @@ derive_params_growth_height <- function(dataset,
mutate(!!!set_values_to_pctl)

dataset_final <- bind_rows(dataset_final, add_pctl, unmatched_pctl) %>%
select(-c(L, M, S, sex_join, heightu_join, meta_height))
select(-c(L, M, S, sex_join, heightu_join, meta_height, temp_val, temp_z))
}

dataset_final <- dataset_final %>%
select(-c(SD2pos, SD3pos, SD2neg, SD3neg, ht_bins, temp_z, temp_val))
select(-c(SD2pos, SD3pos, SD2neg, SD3neg, ht_bins))

return(dataset_final)
}

0 comments on commit 314c097

Please sign in to comment.