Install R and RStudio on Ubuntu
2015-09-23 21:40
676 查看
I wanted to try Linux system thus I formatted an old laptop bought 7 years ago (HP Pavilion dm3, French keyboard).
No doubt that I need R and RStudio to be installed on this laptop…
Installed that, I tried to installed packages “dplyr” but failed - error message told me that the current version is ver. 3.0.x…
That definitely doesn’t meet my needs because I’m using ver. 3.2.2 on WIN7. We need to remove it and reinstall it by cmd line.
The first thing to do is to “add an entry in your /etc/apt/sources.list file” (one of the 3 lines below, anyone is OK):
Where “https://
Again! IT IS NOT A COMMAND!
Remember that I’ve already installed R of an older version, I need to remove that beforehand. Ignore that if you never install it.
According to the official instruction, to install the complete R system, use:
But that didn’t work, I got an error message:
By scrolling down the instruction:
The Ubuntu archives on CRAN are signed with the key of “Michael Rutter marutter@gmail.com” with key ID E084DAB9.
To add the key to your system and finish the installation with the commands:
Reference:
Installing latest version of R-base
No doubt that I need R and RStudio to be installed on this laptop…
Install R
Software Center
In the software center, you can easily find an official R app under Category “Science & Engineering :: Mathematics”.Installed that, I tried to installed packages “dplyr” but failed - error message told me that the current version is ver. 3.0.x…
That definitely doesn’t meet my needs because I’m using ver. 3.2.2 on WIN7. We need to remove it and reinstall it by cmd line.
Cmd Lines
On Cran-R homepage, there is an index led to Ubuntu installation instruction.The first thing to do is to “add an entry in your /etc/apt/sources.list file” (one of the 3 lines below, anyone is OK):
deb https://<my.favorite.cran.mirror>/bin/linux/ubuntu vivid/ deb https://<my.favorite.cran.mirror>/bin/linux/ubuntu trusty/ deb https://<my.favorite.cran.mirror>/bin/linux/ubuntu precise/
Where “https://
deb http://cran.rstudio.com/bin/linux/ubuntu precise/
Again! IT IS NOT A COMMAND!
Remember that I’ve already installed R of an older version, I need to remove that beforehand. Ignore that if you never install it.
sudo apt-get remove r-base-core
According to the official instruction, to install the complete R system, use:
sudo apt-get update sudo apt-get install r-base
But that didn’t work, I got an error message:
The following packages have unmet dependencies: r-base : Depends: r-base-core (>= 3.2.2-1ubuntu0) but it is not going to be installed Depends: r-recommended (= 3.2.2-1ubuntu0) but it is not going to be installed Recommends: r-base-html but it is not going to be installed E: Unable to correct problems, you have held broken packages.
By scrolling down the instruction:
The Ubuntu archives on CRAN are signed with the key of “Michael Rutter marutter@gmail.com” with key ID E084DAB9.
To add the key to your system and finish the installation with the commands:
sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys E084DAB9 sudo add-apt-repository ppa:marutter/rdev sudo apt-get update sudo apt-get upgrade sudo apt-get install r-base
Install RStudio
To install RStudio, you can directly download the .deb package from https://www.rstudio.com/products/rstudio/download/. Once it’s downloaded, software center will pop up a window asking for installation.Reference:
Installing latest version of R-base
相关文章推荐
- Ubuntu 默认壁纸历代记
- Ubuntu Remix Cinnamon 20.04 评测:Ubuntu 与 Cinnamon 的完美融合
- Linux socket 初步
- 关于Ubuntu 11.10启动提示waiting for the network configuration的问题
- 在 Ubuntu 桌面中使用文件和文件夹
- linux lsof详解
- 10 篇对初学者和专家都有用的 Linux 命令教程
- Linux 与 Windows 对UNICODE 的处理方式
- Ubuntu12.04下QQ完美走起啊!走起啊!有木有啊!
- 解決Linux下Android开发真机调试设备不被识别问题
- ubuntu下chrome无法同步问题解决
- 运维入门
- 运维提升
- Linux 自检和 SystemTap
- Ubuntu Linux使用体验
- c语言实现hashmap(转载)
- Linux 信号signal处理机制
- linux下mysql添加用户