I am unable to install packages through latest version of RStudio and R Version.3.1.1.
Kindly help. I got the error as mentioned below:
Example: Warning in install.packages : InternetOpenUrl failed: '' Warning in install.packages : InternetOpenUrl failed: '' Warning in install.packages : unable to access index for repository http://cran.rstudio.com/bin/windows/contrib/3.1 Installing package into ‘C:/Users/Documents/R/win-library/3.1’ (as ‘lib’ is unspecified) Warning in install.packages : InternetOpenUrl failed: '' Warning in install.packages : InternetOpenUrl failed: '' Warning in install.packages : unable to access index for repository http://cran.rstudio.com/bin/windows/contrib/3.1 Warning in install.packages : package ‘reshape’ is not available (for R version 3.1.1)
Solution 2: Use RStudioChanging the configuration in R Studio to solve install packages issue. Go To Tools -> Global option -> Packages. Then uncheck the option “Use secure download method for HTTP”. For other RStudio issues refer to official Troubleshooting Guide here.
I wonder, can I do any harm to my system (or the stability of R installation) if I install some package twice. Or when installing a new package it will simply overwrite the previous version. It shouldn't be an issue unless you install a package as an admin user, and again as a normal user.
If you only want to update a single package, the best way to do it is using install. packages() again. In RStudio, you can also manage packages using Tools -> Install Packages.
If you want to update to the latest version of RStudio, hover over “Help” on the top menu bar of your Mac, and click “Check for Updates”. Then, quit the RStudio program, go to the RStudio website, and download and install the latest version. Now you should have the latest versions of R and RStudio on your computer.
Not 100% certain that you have the same problem, but I found out the hard way that my job blocks each mirror site option that was offered and I was getting errors like this:
Installing package into ‘/usr/lib64/R/library’ (as ‘lib’ is unspecified) --- Please select a CRAN mirror for use in this session --- Error in download.file(url, destfile = f, quiet = TRUE) : unsupported URL scheme Warning: unable to access index for repository https://rweb.crmda.ku.edu/cran/src/contrib Warning message: package ‘ggplot2’ is not available (for R version 3.2.2)
Workaround (I am using CentOS)...
install.packages('package_name', dependencies=TRUE, repos='http://cran.rstudio.com/')
I hope this saves someone hours of frustration.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With