library(tidymodels) not loading and not able to install rstanarm

415 Views Asked by At

Error received while trying to load tidymodels

Error: package or namespace load failed for ‘tidymodels’ in loadNamespace(j <- i[[1L]], c(lib.loc, .libPaths()), versionCheck = vI[[j]]): there is no package called ‘rstanarm’

Error received while trying to install ‘rstanarm’

installing the source package ‘rstanarm’

trying URL 'https://cran.rstudio.com/src/contrib/rstanarm_2.19.3.tar.gz'
Content type 'application/x-gzip' length 3534835 bytes (3.4 MB)
==================================================
downloaded 3.4 MB

* installing *source* package ‘rstanarm’ ...
** package ‘rstanarm’ successfully unpacked and MD5 sums checked
** using staged installation
** libs
xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun at: /Library/Developer/CommandLineTools/usr/bin/xcrun
ERROR: compilation failed for package ‘rstanarm’
* removing ‘/Library/Frameworks/R.framework/Versions/3.6/Resources/library/rstanarm’
Warning in install.packages :
  installation of package ‘rstanarm’ had non-zero exit status
0

There are 0 best solutions below