无法在最新版本的 RStudio 和 R Version.3.1.1 中安装软件包 [英] Unable to install packages in latest version of RStudio and R Version.3.1.1
本文介绍了无法在最新版本的 RStudio 和 R Version.3.1.1 中安装软件包的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我无法通过最新版本的 RStudio 和 R Version.3.1.1.
安装软件包.请帮忙.我收到如下错误:
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)
推荐答案
不能 100% 确定您有同样的问题,但我发现我的工作很难阻止提供的每个镜像站点选项,并且我得到了像这样的错误:
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)
解决方法(我使用 CentOS)...
Workaround (I am using CentOS)...
install.packages('package_name', dependencies=TRUE, repos='http://cran.rstudio.com/')
我希望这可以为某些人节省数小时的挫败感.
I hope this saves someone hours of frustration.
这篇关于无法在最新版本的 RStudio 和 R Version.3.1.1 中安装软件包的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文