0

Not able to download packages on rstudio

the below code returned the following response

> options(download.file.method="libcurl")
WARNING: You are configured to use the CRAN mirror at https://cran.rstudio.com/. This mirror supports secure (HTTPS) downloads however your system is unable to communicate securely with the server (possibly due to out of date certificate files on your system). Falling back to using insecure URL for this mirror.

also , this code returned the following message:

> options(repos = c(CRAN = "http://cloud.r-project.org")); available.packages()
Warning: unable to access index for repository http://cloud.r-project.org/src/contrib:
cannot open URL 'http://cloud.r-project.org/src/contrib/PACKAGES'
Package Version Priority Depends Imports LinkingTo Suggests Enhances License License_is_FOSS
License_restricts_use OS_type Archs MD5sum NeedsCompilation File Repository

Could anyone please help?

Thomas
  • 43,637
  • 12
  • 109
  • 140
Aman Mehta
  • 1
  • 1
  • 2
  • It seems that your system is earnestly trying to block ability to download packages. It might be tricky to solve it by hand. You can download packages directly from web pages - tar.gz files and install them via RStudio instead. In tab 'packages' and install pick install from file instead of install via CRAN. – Adamm Dec 04 '17 at 06:26
  • can you send a link from where i can download packages ? – Aman Mehta Dec 04 '17 at 06:36
  • `https://cran.r-project.org/web/packages/package_name/` or `https://CRAN.R-project.org/package=package_name` or type in R `install.packages("package_name", dependencies = T)` – Adamm Dec 04 '17 at 06:44
  • you can try to run `R` or `Rstudio` as the admin – Mateusz1981 Dec 04 '17 at 06:46
  • manually downloading and installing also didnt work ..it returned this - Warning in install.packages : running command '"C:/Users/A0758190/Documents/R/R-3.4.2/bin/i386/R" CMD INSTALL -l "C:\Users\A0758190\Documents\R\R-3.4.2\library" "C:/Users/A0758190/Downloads/xlsx_0.5.7.tar.gz"' had status 1 Warning in install.packages : installation of package ‘C:/Users/A0758190/Downloads/xlsx_0.5.7.tar.gz’ had non-zero exit status – Aman Mehta Dec 04 '17 at 07:21
  • Make sure your user has write access to the library folder. – Elin Dec 18 '17 at 16:10

0 Answers0