When trying to install ggplot2 I get the following code at the end of the installation:
'''
- installing source package 'ggplot2' ...
** package 'ggplot2' successfully unpacked and MD5 sums checked
** R
** data
*** moving datasets to lazyload DB
** inst
** preparing package for lazy loading
Error in loadNamespace(i, c(lib.loc, .libPaths()), versionCheck = vI[[i]]) :
there is no package called 'colorspace'
ERROR: lazy loading failed for package 'ggplot2' - removing 'C:/Users/Beefgallo/Documents/R/win-library/3.4/ggplot2'
In R CMD INSTALL
Warning in install.packages :
running command '"C:/PROGRA~1/R/R-34~1.4/bin/x64/R" CMD INSTALL -l "C:\Users\Beefgallo\Documents\R\win-library\3.4" C:\Users\BEEFGA~1\AppData\Local\Temp\RtmpwJMpHe/downloaded_packages/ggplot2_3.3.0.tar.gz' had status 1
Warning in install.packages :
installation of package ‘ggplot2’ had non-zero exit status
'''
I tried following the suggestions in this thread:
https://forum.posit.co/t/problem-installing-ggplot2-packages/10956/9
including installing ggplot2 with all dependencies, installing the rlang package, installing the latest version or R, nothing works.
Any ideas as to what could be causing this?