我正在尝试安装R studio包。 我正在运行R作为" datacleaning"用户此用户
从本地来源安装了一些软件包:
if (!require("SparseM", lib=lib.path)) install.packages("/dc/R/p1/SparseM_1.7.gz", repos = NULL, type="source", lib=lib.path)
其他人直接来自R cran
if (!require("stringr", lib=lib.path)) install.packages("stringr", lib=lib.path, repos=url.cran)
这就是安装包目录的样子:
drwxrwxr-x 7 root root 4096 feb 8 15:15 base64enc
drwxrwxr-x 8 datacleaning users 4096 feb 8 15:11 bit
drwxrwxr-x 9 root root 4096 feb 8 15:19 bit64
drwxrwxr-x 9 root root 4096 feb 8 15:16 data.table
drwxrwxr-x 6 root root 4096 feb 8 15:15 evaluate
drwxrwxr-x 9 root root 4096 feb 8 15:15 foreign
drwxrwxr-x 11 root root 4096 feb 8 15:16 gdata
drwxrwxr-x 8 root root 4096 feb 8 15:16 gtools
drwxrwxr-x 7 root root 4096 feb 8 15:15 highr
drwxrwxr-x 14 datacleaning users 4096 feb 8 15:15 knitr
drwxrwxr-x 7 root root 4096 feb 8 15:15 magrittr
drwxrwxr-x 11 root root 4096 feb 8 15:15 markdown
drwxrwxr-x 7 datacleaning users 4096 feb 8 15:11 mime
drwxrwxr-x 8 datacleaning users 4096 feb 8 15:16 plyr
drwxrwxr-x 16 datacleaning users 4096 feb 8 15:16 Rcpp
drwxrwxr-x 8 datacleaning users 4096 feb 8 15:16 reshape2
drwxrwxr-x 6 datacleaning users 4096 feb 8 15:15 sendmailR
drwxrwxr-x 8 datacleaning users 4096 feb 8 15:15 stringi
drwxrwxr-x 9 root root 4096 feb 8 15:15 stringr
drwxrwxr-x 8 datacleaning users 4096 feb 8 15:11 xtable
drwxrwxr-x 7 root root 4096 feb 8 15:15 yaml
为什么安装的软件包所有权成为root用户?某些包依赖项正在尝试访问这些根包。但后来我无权访问root包。
也许我错过了关于R软件包安装的一些内容