即使具有PC管理员权限,也无法安装R包

时间:2015-01-09 09:59:10

标签: r ggplot2 install packages

我一直试图在我的系统上安装ggplot2软件包很长一段时间。我在安全的办公环境中工作,因此需要清除防火墙问题/管理员权限问题。我部分意识到这一点,并取得了我的机器的管理员权限。我看过this但仍然没有成功。 我以前没有在这个系统上安装R包。 在我的个人电脑上安装了R软件包,它们工作正常。

代码和评论如下:

> install.packages("ggplot2")
Installing package into ‘D:/Rlib’
(as ‘lib’ is unspecified)
also installing the dependencies ‘colorspace’, ‘Rcpp’, ‘stringr’, ‘RColorBrewer’, ‘dichromat’, ‘munsell’, ‘labeling’, ‘plyr’, ‘digest’, ‘gtable’, ‘reshape2’, ‘scales’, ‘proto’

trying URL 'http://cran.rstudio.com/bin/windows/contrib/3.1/colorspace_1.2-4.zip'
Content type 'text/html; charset=UTF-8' length 1627 bytes
opened URL
downloaded 1627 bytes

trying URL 'http://cran.rstudio.com/bin/windows/contrib/3.1/Rcpp_0.11.3.zip'
Content type 'text/html; charset=UTF-8' length 1625 bytes
opened URL
downloaded 1625 bytes

trying URL 'http://cran.rstudio.com/bin/windows/contrib/3.1/stringr_0.6.2.zip'
Content type 'text/html; charset=UTF-8' length 1625 bytes
opened URL
downloaded 1625 bytes

trying URL 'http://cran.rstudio.com/bin/windows/contrib/3.1/RColorBrewer_1.1-2.zip'
Content type 'text/html; charset=UTF-8' length 1629 bytes
opened URL
downloaded 1629 bytes

trying URL 'http://cran.rstudio.com/bin/windows/contrib/3.1/dichromat_2.0-0.zip'
Content type 'text/html; charset=UTF-8' length 1629 bytes
opened URL
downloaded 1629 bytes

trying URL 'http://cran.rstudio.com/bin/windows/contrib/3.1/munsell_0.4.2.zip'
Content type 'text/html; charset=UTF-8' length 1627 bytes
opened URL
downloaded 1627 bytes

trying URL 'http://cran.rstudio.com/bin/windows/contrib/3.1/labeling_0.3.zip'
Content type 'text/html; charset=UTF-8' length 1625 bytes
opened URL
downloaded 1625 bytes

trying URL 'http://cran.rstudio.com/bin/windows/contrib/3.1/plyr_1.8.1.zip'
Content type 'text/html; charset=UTF-8' length 1627 bytes
opened URL
downloaded 1627 bytes

trying URL 'http://cran.rstudio.com/bin/windows/contrib/3.1/digest_0.6.8.zip'
Content type 'text/html; charset=UTF-8' length 1629 bytes
opened URL
downloaded 1629 bytes

trying URL 'http://cran.rstudio.com/bin/windows/contrib/3.1/gtable_0.1.2.zip'
Content type 'text/html; charset=UTF-8' length 1627 bytes
opened URL
downloaded 1627 bytes

trying URL 'http://cran.rstudio.com/bin/windows/contrib/3.1/reshape2_1.4.1.zip'
Content type 'text/html; charset=UTF-8' length 1627 bytes
opened URL
downloaded 1627 bytes

trying URL 'http://cran.rstudio.com/bin/windows/contrib/3.1/scales_0.2.4.zip'
Content type 'text/html; charset=UTF-8' length 1629 bytes
opened URL
downloaded 1629 bytes

trying URL 'http://cran.rstudio.com/bin/windows/contrib/3.1/proto_0.3-10.zip'
Content type 'text/html; charset=UTF-8' length 1627 bytes
opened URL
downloaded 1627 bytes

trying URL 'http://cran.rstudio.com/bin/windows/contrib/3.1/ggplot2_1.0.0.zip'
Content type 'text/html; charset=UTF-8' length 1627 bytes
opened URL
downloaded 1627 bytes

Warning in install.packages :
  error 1 in extracting from zip file
Warning in install.packages :
  cannot open compressed file 'colorspace/DESCRIPTION', probable reason 'No such file or directory'
Error in install.packages : cannot open the connection

P.S。:我添加了一个.libPaths()文件夹,我拥有完整的权利。这应该否定许可问题,对吗?

1 个答案:

答案 0 :(得分:3)

@CMichael可能是对的。我不知道下载了什么,但快速检查你的列表中的任何CRAN包将显示它们的大小远大于1625字节。几乎可以肯定,由于防火墙阻塞,每种情况下都会出现错误消息。

下载或sneakernet zip文件并在本地安装。