在Ubuntu机器上安装R版本3.0.2 (2013-09-25)的软件包时,我遇到了这个问题:
install.packages("randomForest")
Installing package into ‘/usr/local/lib/R/site-library’
(as ‘lib’ is unspecified)
Warning in install.packages :
'lib = "/usr/local/lib/R/site-library"' is not writable
如何解决?
发布于 2017-07-11 21:54:24
将您自己添加到名为“staff”的组中
sudo usermod -a -G staff your_user_name
将your_user_name替换为您的登录用户名,然后注销并重新登录。
不要使用chmod 777,这是对安全性和btw的破坏。完全是胡说八道!
发布于 2018-02-24 06:20:40
如果您使用的是Windows,则可以以管理员身份运行R(或RStudio)。
关闭R,然后转到R或RStudio图标,右键单击并“以管理员身份打开”。它工作完美,安装包时的所有错误消息都将永远消失。
发布于 2015-09-13 00:22:51
这就是它所说的意思。您在该文件夹中没有写入权限。你要么需要change the permissions for that folder,要么需要change the R library location。
https://stackoverflow.com/questions/32540919
复制相似问题