如何在linux環境下安裝R包

來源:互聯網
上載者:User
Then Install BioConductor PackagesRight now, the easiest way to install BioConductor packages is using the biocLite.R installation script. Here's how to use it: 
In an R command window, type the following:
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
source(">
將包下載下來,在命令列下:
>R CMD INSTALL -l 你要安裝的目錄 *.gz(你的包的)
我的方法是:
把包下載到本地
>install.packages("package_path",repos=NULL)
Commands:
INSTALL Install add-on packages
Please use 'R CMD command --help' to obtain further information about
the usage of 'command'.
建議還是用這個穩妥些。
source("http://www.bioconductor.org/biocLite.R")
biocLite(c("pkg1", "pkg2")) 
#Where "pkg1" and "pkg2" are the names of the packages you would like to install.

因為R package涉及到R本身版本高低,已安裝的依賴包的版本的高低,辛苦
down下來包包可能根本不匹配,也就用不了。biocLite指令碼能夠自動處理這些,保證安裝的package可用。
R CMD是很cool的命令。但犯linux的通病,複雜的依賴關係。
而biocLite就非常像FC6 linux下的yum,只要網路好,這種安裝無疑是省體力的。
相關文章

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.