cannot load any packages in rstudio - mac OS

no packages will install, ive added the beginning of the code as well as the end below. let me know if you have a solution - R version 3.6.3

install.packages("tidyverse")
also installing the dependencies ‘sys’, ‘bit’, ‘ps’, ‘sass’, ‘cachem’, ‘memoise’, ‘base64enc’, ‘fastmap’, ‘rappdirs’, ‘rematch’, ‘askpass’, ‘bit64’, ‘prettyunits’, ‘processx’, ‘highr’, ‘yaml’, ‘xfun’, ‘bslib’, ‘htmltools’, ‘jquerylib’, ‘tinytex’, ‘backports’, ‘ellipsis’, ‘assertthat’, ‘blob’, ‘cli’, ‘tidyselect’, ‘vctrs’, ‘rlang’, ‘data.table’, ‘scales’, ‘gargle’, ‘uuid’, ‘cellranger’, ‘curl’, ‘ids’, ‘rematch2’, ‘mime’, ‘openssl’, ‘clipr’, ‘vroom’, ‘tzdb’, ‘progress’, ‘callr’, ‘fs’, ‘knitr’, ‘rmarkdown’, ‘selectr’, ‘stringi’, ‘broom’, ‘dbplyr’, ‘dplyr’, ‘dtplyr’, ‘forcats’, ‘ggplot2’, ‘googledrive’, ‘googlesheets4’, ‘haven’, ‘hms’, ‘httr’, ‘jsonlite’, ‘lubridate’, ‘modelr’, ‘pillar’, ‘purrr’, ‘readr’, ‘readxl’, ‘reprex’, ‘rvest’, ‘stringr’, ‘tidyr’, ‘xml2’


  There are binary versions available but the source versions are later:
               binary source needs_compilation
ps              1.6.0  1.7.1              TRUE
sass            0.4.0  0.4.2              TRUE
processx        3.5.2  3.7.0              TRUE
yaml            2.2.2  2.3.5              TRUE
xfun             0.29   0.32              TRUE
bslib         0.2.5.1  0.4.0             FALSE
htmltools       0.5.2  0.5.3              TRUE
tinytex          0.36   0.41             FALSE
blob            1.2.2  1.2.3             FALSE
cli             3.1.1  3.3.0              TRUE
tidyselect      1.1.1  1.1.2              TRUE
vctrs           0.3.8  0.4.1              TRUE
rlang           1.0.1  1.0.4              TRUE
scales          1.1.1  1.2.1             FALSE
uuid            1.0-3  1.1-0              TRUE
openssl         1.4.6  2.0.2              TRUE
clipr           0.7.1  0.8.0             FALSE
tzdb            0.2.0  0.3.0              TRUE
callr           3.7.0  3.7.2             FALSE
knitr            1.37   1.40             FALSE
rmarkdown        2.11   2.16             FALSE
stringi         1.7.6  1.7.8              TRUE
broom          0.7.12  1.0.1             FALSE
dbplyr          2.1.1  2.2.1             FALSE
dplyr           1.0.8  1.0.9              TRUE
dtplyr          1.2.1  1.2.2             FALSE
forcats         0.5.1  0.5.2             FALSE
ggplot2         3.3.5  3.3.6             FALSE
googlesheets4   1.0.0  1.0.1             FALSE
haven           2.4.3  2.5.1              TRUE
hms             1.1.1  1.1.2             FALSE
httr            1.4.2  1.4.4             FALSE
jsonlite        1.7.2  1.8.0              TRUE
modelr          0.1.8  0.1.9             FALSE
pillar          1.7.0  1.8.1             FALSE
readxl          1.3.1  1.4.1              TRUE
reprex          2.0.1  2.0.2             FALSE
rvest           1.0.1  1.0.3             FALSE
stringr         1.4.0  1.4.1             FALSE
tidyverse       1.3.1  1.3.2             FALSE

Do you want to install from sources the packages which need compilation? (Yes/no/cancel) no
trying URL 'https://cran.rstudio.com/bin/macosx/el-capitan/contrib/3.6/sys_3.4.tgz'
Content type 'application/x-gzip' length 47455 bytes (46 KB)
==================================================
downloaded 46 KB

trying URL 'https://cran.rstudio.com/bin/macosx/el-capitan/contrib/3.6/bit_4.0.4.tgz'
Content type 'application/x-gzip' length 694343 bytes (678 KB)

this will then lead to no packages being able to install. here is the last part of the code:

Error in loadNamespace(i, c(lib.loc, .libPaths()), versionCheck = vI[[i]]) : 
  namespace ‘rlang’ 1.0.1 is being loaded, but >= 1.0.2 is required
Calls: <Anonymous> ... withCallingHandlers -> loadNamespace -> namespaceImport -> loadNamespace
Execution halted
ERROR: lazy loading failed for package ‘googlesheets4’
* removing ‘/Library/Frameworks/R.framework/Versions/3.6/Resources/library/googlesheets4’
Warning in install.packages :
  installation of package ‘googlesheets4’ had non-zero exit status
* installing *source* package ‘rvest’ ...
** package ‘rvest’ successfully unpacked and MD5 sums checked
** using staged installation
** R
** demo
** inst
** byte-compile and prepare package for lazy loading
** help
*** installing help indices
*** copying figures
** building package indices
** installing vignettes
** testing if installed package can be loaded from temporary location
** testing if installed package can be loaded from final location
** testing if installed package keeps a record of temporary installation path
* DONE (rvest)
* installing *source* package ‘rmarkdown’ ...
** package ‘rmarkdown’ successfully unpacked and MD5 sums checked
** using staged installation
** R
** inst
** byte-compile and prepare package for lazy loading
** help
*** installing help indices
*** copying figures
** building package indices
** installing vignettes
** testing if installed package can be loaded from temporary location
** testing if installed package can be loaded from final location
** testing if installed package keeps a record of temporary installation path
* DONE (rmarkdown)
ERROR: dependency ‘ggplot2’ is not available for package ‘broom’
* removing ‘/Library/Frameworks/R.framework/Versions/3.6/Resources/library/broom’
Warning in install.packages :
  installation of package ‘broom’ had non-zero exit status
ERROR: dependency ‘broom’ is not available for package ‘modelr’
* removing ‘/Library/Frameworks/R.framework/Versions/3.6/Resources/library/modelr’
Warning in install.packages :
  installation of package ‘modelr’ had non-zero exit status
ERROR: dependency ‘callr’ is not available for package ‘reprex’
* removing ‘/Library/Frameworks/R.framework/Versions/3.6/Resources/library/reprex’
Warning in install.packages :
  installation of package ‘reprex’ had non-zero exit status
ERROR: dependencies ‘broom’, ‘dbplyr’, ‘dtplyr’, ‘ggplot2’, ‘googlesheets4’, ‘modelr’, ‘pillar’, ‘reprex’ are not available for package ‘tidyverse’
* removing ‘/Library/Frameworks/R.framework/Versions/3.6/Resources/library/tidyverse’
Warning in install.packages :
  installation of package ‘tidyverse’ had non-zero exit status

The downloaded source packages are in
	‘/private/var/folders/bk/d467v8xn61scpyq3r1_3ty100000gn/T/RtmpV7Tza9/downloaded_packages’

any help would be appreciated

You are issuing a very old R version so there are no precompiled binaries of the latest package versions available for it, you would need to compile from source so you need to answer "yes" to this question.

Be aware that you need to have the required compilers installed in your system for this to work and that it is possible that some packages might not even support such an old R version.

Thanks the the tip!
I have tried "Yes" as well, but i am also not able to load anything.
How would I determine which compilers I need, and where can I install these compilers from?

I'm assuming you are on a macOS system so this would be the official documentation for the build tools

https://cran.r-project.org/bin/macosx/tools

But to give you any specific advice we would need to see the actual error messages you get.

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.