I'm trying to be "that reviewer" that has no idea what they are doing with GitHub or R. (not that far from the truth).
Running spectra-trait_reseco_lma_plsr_example.R
I had some issues getting started, but will make that a different issue.
Once I had a the code running in R Studio (v1.4, with R 4.0.3), these are potential issues.
At Line 31: install devtools. Outputs list of packages (n = 56). Instructions about "enter one or more numbers" seem to be repeated and confusing.
…
56: readr (1.3.1 -> 1.4.0 ) [CRAN]
Enter one or more numbers, or an empty line to skip updates:list.of.packages <- c("pls","dplyr","reshape2","here","plotrix","ggplot2","gridExtra","spectratrait")
Enter one or more numbers, or an empty line to skip updates:invisible(lapply(list.of.packages, library, character.only = TRUE))
Enter one or more numbers, or an empty line to skip updates:#--------------------------------------------------------------------------------------------------#
Enter one or more numbers, or an empty line to skip updates:
Entered “1”
Next output message:
There are binary versions available but the source versions are later:
binary source needs_compilation
waldo 0.2.3 0.2.4 FALSE
promises 1.1.1 1.2.0.1 TRUE
Do you want to install from sources the package which needs compilation? (Yes/no/cancel)
Entered “Yes” (maybe guidance to this should be given in instructions).
Continued running chunks, all working until Line 99.
Error in sample_info %>% select(Plant_Species = Latin Species
, Species_Code = species code
, :
could not find function "%>%"
Tried to load packages that might help with "%>%"
library(dplyr)
Error: package or namespace load failed for ‘dplyr’ in loadNamespace(i, c(lib.loc, .libPaths()), versionCheck = vI[[i]]):
namespace ‘rlang’ 0.4.7 is already loaded, but >= 0.4.9 is required
library(magrittr)
Error in value[3L] :
Package ‘magrittr’ version 1.5 cannot be unloaded:
Error in unloadNamespace(package) : namespace ‘magrittr’ is imported by ‘tibble’, ‘testthat’ so cannot be unloaded
Testing ended at this point. Unable to continue.
I have recently used dplr in other code without an issue. Not sure what has changed.