Open aeshjalmur opened 1 month ago
@aeshjalmur Thank you for letting me know. Do you mind telling me what version of R you are using?
I am using R version 4.0.0 (2020-04-24) -- "Arbor Day" Copyright (C) 2020 The R Foundation for Statistical Computing Platform: x86_64-w64-mingw32/x64 (64-bit).
Additionnally, I tried the codebook function from the package, and it did not work for me as it displayed the following error which I could not solve: Erreur : 'reframe' is not an exported object from 'namespace:dplyr'
Hi @aeshjalmur, That makes sense.
cb_summary_stats_numeric
doesn't work on your computer.reframe()
function was added to the dplyr
package in version 1.1.0. If you are using an older version of dplyr
, that would explain the "Erreur : 'reframe' is not an exported object from 'namespace:dplyr'".You should be able to fix these errors by updating base R and dplyr
. However, you may have a good reason for not wanting to do so. On my end, I think I can, and should, update the dependency file to indicate that base R version 4.1 or greater and dplyr
version 1.1 or greater are required by this package.
Attempting installation of codebooker in R 4.0 results in the following error which aborts installation:
cb_summary_stats_numeric.R:30:54: unexpected input 29: # Format output 30: dplyr::mutate(dplyr::across(dplyr::everything(), \ ^ ERROR: unable to collate and parse R files for package 'codebookr'
The affected lines of file cb_summary_stats_numeric.R are:
29 # Format output 30 dplyr::mutate(dplyr::across(dplyr::everything(), (x) round(x, digits = digits))) %>% 31 dplyr::mutate(dplyr::across(dplyr::everything(), (x) format(x, nsmall = digits)))
The dash syntax seems to be incompatible with R
Replacement by the following lines solved the installation issue, but I do not know yet if the package will remain functional after this substitution : 29 # Format output 30 dplyr::mutate(dplyr::across(dplyr::everything(), ~ round(.x, digits = digits))) %>% 31 dplyr::mutate(dplyr::across(dplyr::everything(), ~ format(.x, nsmall = digits)))
Best