centos7 r語言安裝 centOS7安裝R

2021-10-12 15:31:07 字數 2302 閱讀 2728

在安裝時發現一般教程中說的 yum install r 這個命令不管用了啊,然後去官網了解了一波 ,發現官網上表示r語言已經屬於epel倉庫管理了。

1.安裝epel倉庫

yum install epel-release

隨後報錯:

這是由於centos7自帶的python版本為2.7,因此要將該檔案的python頭資訊修改為python2.7

2.安裝r

yum install r

出現報錯資訊:

running transaction test

transaction check error:

transaction check error:

file /usr/share/locale/en/lc_messages/systemtap.mo from install of systemtap-2.7-2.el6.x86_64 conflicts with file from package systemtap-client-2.5-5.el6.x86_64

file /usr/share/locale/fr/lc_messages/systemtap.mo from install of systemtap-2.7-2.el6.x86_64 conflicts with file from package systemtap-client-2.5-5.el6.x86_64

file /usr/share/locale/pl/lc_messages/systemtap.mo from install of systemtap-2.7-2.el6.x86_64 conflicts with file from package systemtap-client-2.5-5.el6.x86_64

file /usr/share/locale/en/lc_messages/systemtap.mo from install of systemtap-2.7-2.el6.x86_64 conflicts with file from package systemtap-devel-2.5-5.el6.x86_64

file /usr/share/locale/fr/lc_messages/systemtap.mo from install of systemtap-2.7-2.el6.x86_64 conflicts with file from package systemtap-devel-2.5-5.el6.x86_64

file /usr/share/locale/pl/lc_messages/systemtap.mo from install of systemtap-2.7-2.el6.x86_64 conflicts with file from package systemtap-devel-2.5-5.el6.x86_64

file /usr/share/locale/en/lc_messages/systemtap.mo from install of systemtap-2.7-2.el6.x86_64 conflicts with file from package systemtap-runtime-2.5-5.el6.x86_64

file /usr/share/locale/fr/lc_messages/systemtap.mo from install of systemtap-2.7-2.el6.x86_64 conflicts with file from package systemtap-runtime-2.5-5.el6.x86_64

file /usr/share/locale/pl/lc_messages/systemtap.mo from install of systemtap-2.7-2.el6.x86_64 conflicts with file from package systemtap-runtime-2.5-5.el6.x86_64

error summary

例如*** conflicts with libvirt-client-(版本號)... ...

這是由於我們切換了倉庫導致的依賴版本不一致造成的

首先檢視產生衝突的包

rpm -q libvirt-client

發現只有乙個版本的包,並未出現兩個不同版本的包。因此該衝突並非是由於兩個不同版本的包產生的,而是由於當前倉庫的當前版本的包版本過低。

因此更新當前衝突包。

yum update libvirt-client

然後再輸入:

yum install r

4.r安裝完成後,鍵入『r』即可進入r環境

5.安裝r的擴充套件包

例如安裝『party』科學包

在r環境平台中鍵入命令:

install.packages("party")

Centos7 安裝R語言並安裝R包

1.環境 安裝 1.先執行命令安裝epel倉庫 yum install epel release 2.然後再執行 yum install r 有提示就按 y鍵即可 安裝完成輸入r 提示如下就說明安裝成功了!2.安裝需要的r 包 1.install.packages rms 執行完他會報這個錯 單獨執...

在CentOS 安裝R語言

r 在 configure 時需要接引數 enable r shlib configure prefix usr local enable r shlib 0.安裝yum優先順序外掛程式 yum install yum priorities1.epel簡介 rpm uvh edu cn fedora...

Centos 6 7 8 安裝R語言

2 安裝編譯環境 yum y install gcc yum install glibc headers yum install gcc c yum install gcc gfortran yum install readline devel yum install libxt devel yum...