Have some code which uses tidyr::complete and tidyr::nesting. After recent package updates this code with data it was workign before starts to throw errors.
tidyr::complete(
+ data ,
+ tidyr::nesting(!!!syms(c(config$table$hierarchyKeys(), config$table$isotopeLabel))),
+ tidyr::nesting(!!!syms(c(config$table$fileName , config$table$sampleName, config$table$factorKeys() )))
+ )
Error: Column name `tidyr::nesting(...)` must not be duplicated.
Use .name_repair to specify repair.
> c(config$table$hierarchyKeys(), config$table$isotopeLabel)
[1] "protein_Id" "peptide_Id" "modPeptide_Id" "precursor_Id" "isotope"
c(config$table$fileName , config$table$sampleName, config$table$factorKeys() )
[1] "filename" "sampleName" "celltype_" "class_therapy_progressed_" "Patient_ID"
are valid column names afaik and are present in data.
Tried to work out what the error might be but all seems fine.
expand does not complain
expand(data, tidyr::nesting(!!!syms(c(config$table$hierarchyKeys(), config$table$isotopeLabel))))
# A tibble: 63,964 x 5
expand(data, tidyr::nesting(!!!syms(c(config$table$fileName , config$table$sampleName, config$table$factorKeys() )))
+ )
# A tibble: 50 x 5
...
And there is not intersection among the two lists of column names.
i> intersect(c(config$table$fileName , config$table$sampleName, config$table$factorKeys() ), c(config$table$hierarchyKeys(), config$table$isotopeLabel))
character(0)
Help would be greatly appreciated.
> sessionInfo()
R version 3.6.1 (2019-07-05)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows 10 x64 (build 18362)
Matrix products: default
locale:
[1] LC_COLLATE=English_United Kingdom.1252 LC_CTYPE=English_United Kingdom.1252 LC_MONETARY=English_United Kingdom.1252 LC_NUMERIC=C
[5] LC_TIME=English_United Kingdom.1252
attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] forcats_0.4.0 stringr_1.4.0 dplyr_0.8.3 purrr_0.3.3 tidyr_1.0.0 tibble_2.1.3 ggplot2_3.2.1 tidyverse_1.3.0 readr_1.3.1 LFQService_0.1.5
loaded via a namespace (and not attached):
[1] fastcluster_1.1.25 tidyselect_0.2.5 haven_2.2.0 lattice_0.20-38 colorspace_1.4-1 vctrs_0.2.0 generics_0.0.2 rlang_0.4.2 pillar_1.4.2
[10] withr_2.1.2 glue_1.3.1 DBI_1.0.0 dbplyr_1.4.2 RColorBrewer_1.1-2 ggfortify_0.4.8 modelr_0.1.5 readxl_1.3.1 lifecycle_0.1.0
[19] munsell_0.5.0 gtable_0.3.0 cellranger_1.1.0 rvest_0.3.5 heatmap3_1.1.6 broom_0.5.2 Rcpp_1.0.3 backports_1.1.5 scales_1.1.0
[28] jsonlite_1.6 fs_1.3.1 gridExtra_2.3 hms_0.5.2 packrat_0.5.0 stringi_1.4.3 grid_3.6.1 cli_1.1.0 tools_3.6.1
[37] magrittr_1.5 lazyeval_0.2.2 crayon_1.3.4 pkgconfig_2.0.3 zeallot_0.1.0 ellipsis_0.3.0 pheatmap_1.0.12 xml2_1.2.2 reprex_0.3.0
[46] lubridate_1.7.4 assertthat_0.2.1 httr_1.4.1 rstudioapi_0.10 R6_2.4.1 nlme_3.1-142 compiler_3.6.1