R CRAN, install library Rcpp fails after R3.2 upgrade
Asked Answered
U

8

10

I upgraded from R-3.1 to R-3.2. OK ( Standard upgrade)

But this upgrade seems to have lost all the installed packages ( ggplot2, quantmod, Rcpp among dozens and dozens of others).

So installed many from the RStudio tools menu option. Most were successful. But problem with Rcpp (when installing as dependency from ggplot2). The same issue occurs when installing package data.table:

Warning in install.packages :   unable to move temporary installation
‘C:\Users\euclid\Documents\R\win-library\3.2\file40fc19bc2752\colorspace’
to ‘C:\Users\euclid\Documents\R\win-library\3.2\colorspace’ package
‘Rcpp’ successfully unpacked and MD5 sums checked Warning in
install.packages :   unable to move temporary installation
‘C:\Users\euclid\Documents\R\win-library\3.2\file40fc53e26272\Rcpp’ to
‘C:\Users\euclid\Documents\R\win-library\3.2\Rcpp’

Note: The identical error occurs when installing package Rcpp on its own.

Any suggestions appreciated.

Unhorse answered 18/5, 2015 at 16:40 Comment(0)
Y
8

You need to have 'vanilla' session without any packages loaded in order to update those package -- it is a well-known (and still annoying) Windows shortcoming that you cannot update a package which currently had (object) code loaded. As Rcpp comes with a small dll ... you get bitten.

Ysabel answered 18/5, 2015 at 16:52 Comment(3)
Can you explain what a vanilla install should look like? Are you saying not even {stats} should be loaded?Idden
No, base packages are fine. And those do not depend on Rcpp.Ysabel
I read your comment somewhere else about doing apt-get install and that did the trick for me.Idden
C
4

I had the same issue: installed "shiny" but running library(shiny) returns error message saying I have no Rcpp package. Installed Rcpp package and got warning

package ‘Rcpp’ successfully unpacked and MD5 sums checked Warning: unable to move temporary installation The downloaded binary packages are in Temp folder C:\Users\Olga\AppData\Local\Temp\RtmpyOXKt4\downloaded_packages

I opened the above folder and copied folder Rcpp from it into the location where it needs to be. Shiny is up and running now.

Cotten answered 30/9, 2015 at 20:2 Comment(0)
G
3

This may sound odd, but do you have McAfee anti-virus? It turns out that McAfee was preventing the correct installation of 'Rcpp' and 'BH' on my computer (check out this forum for more details: https://github.com/hadley/dplyr/issues/2002). I just temporarily disabled McAfee and installed the package I needed. Worked like a charm.

Galliot answered 7/10, 2016 at 4:4 Comment(0)
P
1

I was doing a first time install with R3.2.0 & installing "devtools" package and faced a similar error:

Warning in install.packages : 
unable to move temporary installation 
‘C:\Users\ravi\Documents\R\win-library\3.2\file1f7414af6d89\Rcpp’ 
to ‘C:\Users\ravi\Documents\R\win-library\3.2\Rcpp’

Many other packages were installed but the Rcpp. And the devtools package wasn't showing up installed (library function failed). After installing just the Rccp package again however the library function worked for me and find_rtools() returned true.

Pinetum answered 16/6, 2015 at 6:14 Comment(0)
E
1

Packages are installed per version in R by default. Changes in the third part of the version number (e.g. 3.1.2 to 3.1.3) don't matter. But changes in the first and second parts (e.g. 3.1.3 to 3.2) do. If you want to move all your packages over, you can rename your library folder from (e.g) 3.1 to 3.2 while R isn't running. Then launch a vanilla R session and run update.packages(). If you're using Bioconductor packages, you'll want to use BiocInstaller::biocLite() instead to upgrade while keeping the current version of Bioconductor or BiocInstaller::biocLite("BiocUpgrade") to upgrade to the newest release. biocLite will by default prompt you to update CRAN packages too.

Note your library folder is by default something like %userprofile%\Documents\R\win-library\3.1.

Eddy answered 16/6, 2015 at 7:26 Comment(0)
K
1

I think this was already mentioned above, but I ran into the same issue. Pay special attention to a few things. First, which packages are missing? For example, when I was installing dplyr, I was missing the dependency Rbcc. So I had to go back and install that package separately. Let the package install into whichever default temporary folder it needs to. In my case, it was C:\Users\Andre\AppData\Local\Temp\Rtmpisa3bO\downloaded_packages\Rcpp. AppData was not visible, so I had to manually type that in. Go and track it down, manually unzip that folder from the .zip to a regular folder. This new folder will be your new package name. Copy that newly unzipped folder to the R library you are working out of. You should now be able to start using it. Hope this helps.

Kaleidoscopic answered 26/6, 2017 at 1:9 Comment(0)
D
0

I first tried installing from a cleaned envionment. Then I tried, after closing R-Studio, manually moving the Rcpp from the temp directory, but files were missing from this install's temp directory. I was finally able to do complete the manual move after downloading the package binary zipfile manually from https://cran.r-project.org/web/packages/Rcpp/index.html which had all of the subfiles, instead of using the temp location generated by install.packages("Rcpp"), or the RStudio environment GUI.

Deceleron answered 25/1, 2016 at 22:20 Comment(0)
C
0

I had the same problem , (and actually just fixed it before someone noticed it was a duplication of this question and directed me here) turned out it was my winzip being unregistered, so not able to unpack the files into the folder I specified, once I extracted them to the appropriate folder myself, it worked no problem.

Com answered 25/10, 2016 at 12:9 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.