When I tried to install packages on my work laptop, I got an error. I\'ve been told that I have full privileges with the laptop, so there should be no blocks.
I thi
RCpp
must be compiled by Rtools
. You should check the path of your Rtools
.
By the way, on my computer (WIN10, R-3.5.1), Rtools
must be installed at C:\Rtools
. If I change the install location, R will not find it.
My problem was fixed by giving me ownership permissions over the Resources/library folder.
The way I solved it, was to go to Recovery Mode (Press Command + R when booting), then go to Utilities > Terminal.
I temporarily disabled the Configuring System Integrity Protection with (WARNING: REMEMBER TO ENABLE IT AFTERWARDS):
csrutil disable
Went back to macOS, right click on the library folder > Get Info > Sharing & Permissions > Click on the lock and enter your admin password > and added myself to read/write.
Restart the mac, enter Recovery Mode again, go to the terminal, and enable the Integrity Protection
csrutil enable
Hope it helps, and please, remember to re-enable the csrutil, your system is very vulnerable in that state, so if you suspect you have some kind of malware, don't use this solution.
A non-zero exit status means in this case that the system failed to install the package. There seem to be a number of unresolved dependencies in the installation process. You could try to resolve this by attempting to install the package using the option dependencies=TRUE
; like this:
install.packages("ggplot2", dependencies=TRUE)
Several of my students have been having problems like this with R3.3.3 (Mac) and R3.5.0 (all). We found that installing devtools
and loading packages from github helped get beyond the odd "non zero exit status" problems, e.g. to get the C50
package at https://github.com/topepo/C5.0:
require("devtools")
install_github("topepo/C5.0")
We tried all of the solutions listed on this page prior to this method finally working.
Hello I got the same problem, I uninstalled R, Rtools, and Rstuido then I downloaded and run as administrator 1)R 2)Rtools and 3)Rstuido
, the order is important, then everything worked fine.
Installing all of the tidyverse packages was the only thing that worked for me.
install.packages("tidyverse")