1. What is the issue? Please be detailed.
I am using ruODK (v1.4.0) in R (R version 4.3.1) to import data from a current survey we are collecting using ODK. For previous surveys, I have used the option within ruODK::odata_submission_rectangle(names_sep = NULL)
to remove the group name prefixes from the variable names that are loaded into R. Currently I am getting an error related to the GPS coordinates collected by ODK:
Error in `tidyr::unnest_wider()`:
ℹ In column: `coordinates`.
ℹ In row: 1.
Caused by error:
! Can't unnest elements with missing names.
ℹ Supply `names_sep` to generate automatic names.
2. What steps can we take to reproduce this issue?
Try importing a survey with GPS coordinates to R using ruODK.
3. What have you tried to fix the issue?
I have tried supplying names_sep
with different patterns, including the default "_". While this prevents the error and allows me to create a dataframe, all of the group names are included as prefixes to the variable names, creating lengthy variable names, which is what the names_sep = NULL
option is designed to avoid.
Session info below:
> sessionInfo()
R version 4.3.1 (2023-06-16)
Platform: aarch64-apple-darwin20 (64-bit)
Running under: macOS Ventura 13.6.1
Matrix products: default
BLAS: /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libBLAS.dylib
LAPACK: /Library/Frameworks/R.framework/Versions/4.3-arm64/Resources/lib/libRlapack.dylib; LAPACK version 3.11.0
locale:
[1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8
time zone: America/New_York
tzcode source: internal
attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] tabulator_1.0.0 ruODK_1.4.0 readxl_1.4.3 RColorBrewer_1.1-3 here_1.0.1 knitr_1.45
[7] lubridate_1.9.3 forcats_1.0.0 stringr_1.5.1 dplyr_1.1.4 purrr_1.0.2 readr_2.1.4
[13] tidyr_1.3.0 tibble_3.2.1 ggplot2_3.4.4 tidyverse_2.0.0
loaded via a namespace (and not attached):
[1] gtable_0.3.4 xfun_0.41 lattice_0.22-5 tzdb_0.4.0 numDeriv_2016.8-1.1 vctrs_0.6.4
[7] tools_4.3.1 generics_0.1.3 curl_5.1.0 sandwich_3.0-2 fansi_1.0.5 pkgconfig_2.0.3
[13] data.table_1.14.8 webshot_0.5.5 lifecycle_1.0.4 compiler_4.3.1 munsell_0.5.0 janitor_2.2.0
[19] carData_3.0-5 snakecase_0.11.1 htmltools_0.5.7 yaml_2.3.7 Formula_1.2-5 crayon_1.5.2
[25] pillar_1.9.0 car_3.1-2 abind_1.4-5 nlme_3.1-163 tidyselect_1.2.0 rvest_1.0.3
[31] digest_0.6.33 stringi_1.8.1 rprojroot_2.0.3 fastmap_1.1.1 grid_4.3.1 colorspace_2.1-0
[37] cli_3.6.1 magrittr_2.0.3 utf8_1.2.4 broom_1.0.5 withr_2.5.2 dreamerr_1.3.0
[43] scales_1.2.1 backports_1.4.1 timechange_0.2.0 rmarkdown_2.25 httr_1.4.7 cellranger_1.1.0
[49] hms_1.1.3 zoo_1.8-12 kableExtra_1.3.4 evaluate_0.23 fixest_0.11.1 viridisLite_0.4.2
[55] rlang_1.1.2 Rcpp_1.0.11 glue_1.6.2 xml2_1.3.5 svglite_2.1.2 rstudioapi_0.15.0
[61] jsonlite_1.8.7 R6_2.5.1 systemfonts_1.0.5 fs_1.6.3 ```