如何在我学校提供的R中安装R包

时间:2018-03-01 23:11:19

标签: r rstudio rstudio-server

我的大学通过VPN提供对RStudio的访问。我可以访问,但我无法安装我通常可以在我的PC上安装的软件包。我知道这是一个广泛的问题,但是有什么想法可以做什么?

这是我尝试安装时的结果:

> install.packages("tm")
Warning in install.packages :
  unable to access index for repository http://cran.rstudio.com/src/contrib:
  object 'status' not found
Installing package into ‘/sscc/home/w/wgm210/R/x86_64-pc-linux-gnu-library/3.3’
(as ‘lib’ is unspecified)
Warning in install.packages :
  unable to access index for repository http://cran.rstudio.com/src/contrib:
  object 'status' not found
Warning in install.packages :
  package ‘tm’ is not available (for R version 3.3.2)
> install.packages("tm", lib="/sscc/opt/R-3.3.2/lib64/R/library")
Warning in install.packages :
  unable to access index for repository http://cran.rstudio.com/src/contrib:
  object 'status' not found
Warning in install.packages :
  'lib = "/sscc/opt/R-3.3.2/lib64/R/library"' is not writable
Would you like to use a personal library instead?  (y/n) y
Warning in install.packages :
  unable to access index for repository http://cran.rstudio.com/src/contrib:
  object 'status' not found
Warning in install.packages :
  package ‘tm’ is not available (for R version 3.3.2)

1 个答案:

答案 0 :(得分:0)

请您的root用户制作" /sscc/opt/R-3.3.2/lib64/R/library"路径可写。

sudo chmod 777 /sscc/opt/R-3.3.2/lib64/R/library