I'm working in R Studio and am attempting to install the dplyr package. I have installed various other packages without problem but have hit a problem with this.
It seems there are various parts to the install, some of these worked but the problem happens when I get 'the dependency BH'. This is the error:
Installing package into ‘\xxxxxxxx.local/Desktops/jagnew/My Documents/R/win-library/3.3’
(as ‘lib’ is unspecified)
also installing the dependency ‘BH’
trying URL 'https://cran.rstudio.com/bin/windows/contrib/3.3/BH_1.62.0-1.zip'
Content type 'application/zip' length 16150075 bytes (15.4 MB)
downloaded 15.4 MB
trying URL 'https://cran.rstudio.com/bin/windows/contrib/3.3/dplyr_0.5.0.zip'
Content type 'application/zip' length 2556205 bytes (2.4 MB)
downloaded 2.4 MB
Error in install.packages : cannot open file '\xxxxxxx.local/Desktops/jagnew/My Documents/R/win-library/3.3/file142032c9327b/BH/include/boost/function/detail/gen_maybe_include.pl': Permission denied
I have changed the directory/libpath as it did not appear that the file was downloading to the correct folder. file142032c9327b is now in the correct path, but path specified in the error is only correct up to /boost, there is no function folder here..?
I'm not sure if this missing folder is the issue, as the error says 'Permission denied', but it seems odd.
Any help would be great.
I had the same issue. Tried doing the following and worked for me:
- Run the RStudio as administrator
- Under the
Packages
tab, click Install
and change Install to Library
option to C:/Program...../R/../library
and select the desired package to install.
Hope it works.
I had the same problem. R gave me an error message whenever I tried to install a new, or update an existing package. I don't remember what the message said exactly, but it was saying "Cannot open file (...) access denied". I tried all the following. Not sure what exactly fixed the problem, but now I can update and/or install new packages:
- Open R/RStudio as administrator;
- Change the R library folder (where packages are installed) security settings, and grant full access to my computer user account. Link1, link2;
- (I think this was what fixed the problem) Follow instructions on this link. It prompted me to install another package, "devtools". Then it worked.
I had faced also this issue. The one and only solution that helped me was to turn off my firewall. Then I was able to download all packages.
I had faced the same issue.
I tried below steps to resolve this issue:
- Launch RGui application.
- Go to
Packages
section and select Install Packages
.
- Select the Package that you want to install from the
Packages
pop up window.
- And click
OK
, that's it package will get successfully installed.
- After following above steps, you can run use your package from
RStudio
.