Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Warning in install.packages: cannot open UR HTTP status was '404 Not Found'

Tags:

r

rstudio

When running install.packages in the latest R (3.4) and RStudio 1.0.143 I get the following warning

Warning in install.packages :
  cannot open URL 'https://cran.rstudio.com/bin/macosx/el-capitan/contrib/3.4/PACKAGES.rds': HTTP status was '404 Not Found'

This appears no matter what package(s) I select, however this does not appear to effect package installation. I tried clearing my ~/.rstudio-desktop, /Library/Frameworks/R.framework/Versions/3.4/Resources/library and reinstalling R and this warning still persists. Evening changing CRAN mirrors appears to have no effect as a similar warning appears. Below is my session information.

R version 3.4.0 (2017-04-21)
Platform: x86_64-apple-darwin15.6.0 (64-bit)
Running under: macOS Sierra 10.12.4

Matrix products: default
BLAS: /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libBLAS.dylib
LAPACK: /Library/Frameworks/R.framework/Versions/3.4/Resources/lib/libRlapack.dylib

locale:
[1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8

attached base packages:
[1] datasets  stats     graphics  grDevices utils     methods   base     

loaded via a namespace (and not attached):
[1] compiler_3.4.0 tools_3.4.0   
like image 632
beigel Avatar asked Apr 29 '17 04:04

beigel


People also ask

Do you want to restart R prior to installing?

Restarting R prior to updating these packages is strongly recommended. RStudio can restart R and then automatically continue the installation after restarting (all work and data will be preserved during the restart).

Does R need Java?

In Windows, both R and Java come in 32-bit and 64-bits architectures. If you install R in both architectures, you must also install Java in both architectures. It is recommended to only install the 64-bit version of R.


2 Answers

Just to let people know: this issue is coming from the R-Studio IDE. It will be fixed in the newest version. For more info: see this link.

EDIT:

With the new version (1.0.153) this issue has been resolved!

like image 160
Manuel R Avatar answered Sep 19 '22 15:09

Manuel R


As @ManualS already acknowledged this is an issue with the RStudio 1.0.143. As long as there is no fix the following workaround works fine:

  1. Close RStudio and start base R
  2. Install package there, either by install.packages("packagename") or by menu "Packages/Install package(s)"
  3. Close base R and start RStudio again

A full support session (for the OneR package) with more details can be found here: https://github.com/vonjd/OneR/issues/4

like image 24
vonjd Avatar answered Sep 22 '22 15:09

vonjd