Returns cleaned field titles for a cohort dataset
decode_column_names(cohort, coded_col_df, r_clean_names = TRUE)
#' @examples
data(coding_dict)
data(cohort)
data(data_dict)
cdata <- merge_coding_data_dict(coding_dict, data_dict)
cohort |>
decode_column_names(cdata)
#> # A tibble: 100 × 18
#> age_at_recruitment coffee_consumed_instance_0 coffee_consumed_instance_1
#> <dbl> <dbl> <dbl>
#> 1 43 NA 1
#> 2 60 NA NA
#> 3 53 NA 0
#> 4 62 NA NA
#> 5 67 NA NA
#> 6 61 NA NA
#> 7 66 NA NA
#> 8 56 NA NA
#> 9 55 NA NA
#> 10 53 NA NA
#> # ℹ 90 more rows
#> # ℹ 15 more variables: coffee_consumed_instance_2 <dbl>,
#> # coffee_consumed_instance_3 <dbl>, coffee_consumed_instance_4 <dbl>,
#> # coffee_intake_instance_0 <dbl>, coffee_intake_instance_1 <dbl>,
#> # coffee_intake_instance_2 <dbl>, coffee_type_instance_0 <dbl>,
#> # coffee_type_instance_1 <dbl>, coffee_type_instance_2 <dbl>,
#> # diagnoses_main_icd10 <chr>, sex <dbl>, sex_of_baby <chr>, …