I have been using R recently. R is statistics programming language. R has attracted more and more attention as analytics in cloud gets more and more hot.

Don't install R in default ubuntu source which only contains a older version. Update apt source according to http://ftp.ctex.org/mirrors/CRAN/. For example, I added the following line to /etc/apt/source.list

deb http://bibs.snu.ac.kr/R/bin/linux/ubuntu jaunty/

Follow the instructions from here

  1. sudo gedit /etc/apt/sources.list

    This will open up your sources.list file in gedit, where you can add the following line.

  2. deb http://cran.cnr.berkeley.edu/bin/linux/ubuntu/ version/

    Replace version/ with whatever version of Ubuntu you are using (eg, precise/oneric/, and so on). If you're getting a "Malformed line error", check to see if you have a space between /ubuntu/and version/.

  3. Fetch the secure APT key with gpg --keyserver keyserver.ubuntu.com --recv-key E084DAB9 or gpg --hkp://keyserver keyserver.ubuntu.com:80 --recv-key E084DAB9.

  4. Feed it to apt-key with gpg -a --export E084DAB9 | sudo apt-key add -

  5. Update your sources and upgrade your installation with sudo apt-get update && sudo apt-get upgrade.

Install R

sudo apt-get install r-base-dev

Install rJava

sudo R CMD javareconf

sudo R to launch RTerm. Issue install.packages('rJava', dependencies=TRUE) to install rJava.

(Installation of rJava needs root permission so sudo it is needed. sudo R is also needed whenever you want to use rJava in Rterm)

sudo R to launch RTern whenever rJava library needs to be used.

There is another way to install rJava. First run `sudo chmod -R 777 /etc/R`. The do all the operations in the previous text without `sudo`.

InstallO Other Packages

Use sudo R to launch RTerm

install.packages('RWeka', dependencies=TRUE)

install.packages('kernlab', dependencies=TRUE)

install.packages('ISwR', dependencies=TRUE)

Install dependencies packages:

- sudo apt-get install libx11-dev

- sudo apt-get install libglu1-mesa-dev

- sudo apt-get install libgl1-mesa-dev

In R console, run

install.packages('Rcmdr', dependencies=TRUE)

To install ggplot2 and caret, don't use dependencies=TRUE. Otherwise, a lot of dependent packages

will be installed. Installation for some of them may fails since some depends on something outside of

R (some ubuntu pacages).

http://yaojingguo.iteye.com/blog/513603

http://stackoverflow.com/questions/10476713/how-to-upgrade-r-in-ubuntu

R on Ubuntu的更多相关文章

  1. Install latest R for ubuntu

    ### delete old version rm -rf /usr/local/lib/R /usr/lib/R ~/**/R sudo apt-get autoremove rstudio sud ...

  2. 拥抱.NET Core,如何开发跨平台的应用并部署至Ubuntu运行

    之前写了一篇博文宣布Rabbit Rpc跨平台了"拥抱.NET Core,跨平台的轻量级RPC:Rabbit.Rpc",在过程中尝试了如何编写支持跨平台的类库与应用程序,也尝试了在 ...

  3. 【转载】Ubuntu 系列安装 Docker

    系统要求 Docker 支持以下版本的Ubuntu操作系统: Ubuntu Xenial 16.04 (LTS) Ubuntu Wily 15.10 Ubuntu Trusty 14.04 (LTS) ...

  4. Ubuntu 12 安装 搜狗输入法

    下载地址:http://pinyin.sogou.com/linux/?r=pinyin Ubuntu 12 中,安装搜狗输入法注意事项 http://pinyin.sogou.com/linux/h ...

  5. Ubuntu学习总结-03 安装软件 & 技巧

    1 UBuntu 安装 Googole Chrome 首先下载软件 wget https://dl.google.com/linux/direct/google-chrome-stable_curre ...

  6. NET Core,Ubuntu运行

    NET Core,如何开发跨平台的应用并部署至Ubuntu运行 之前写了一篇博文宣布Rabbit Rpc跨平台了“拥抱.NET Core,跨平台的轻量级RPC:Rabbit.Rpc”,在过程中尝试了如 ...

  7. [Linux] PHP程序员玩转Linux系列-Ubuntu配置SVN服务器并搭配域名

    在线上部署网站的时候,大部分人是使用ftp,这样的方式很不方便,现在我要在线上安装上SVN的服务器,直接使用svn部署网站.因为搜盘子的服务器是ubuntu,因此下面的步骤是基于ubuntu的. 安装 ...

  8. Ubuntu 安装 Docker CE

    注:本文转载自<Docker入门> 警告:切勿在没有配置 Docker APT 源的情况下直接使用 apt 命令安装 Docker. 准备工作 系统要求 Docker CE 支持以下版本的 ...

  9. Ubuntu 下安装LEMP环境 实战

    ---恢复内容开始--- 1.nginx的服务端的安装 打开命令行终端,在终端输入,sudo apt-get install nginx  回车即开始安装 kxlc-t@ubuntu:~$ sudo ...

随机推荐

  1. ASCII编码表

    最初的编码:ASCII 补充: ASCII表是适用于美国的,共128位:ISO-8859-1是适用于欧洲的,共256位 :GB2312是适用于中文系统的:UTF-8是万国码,适用于绝大部分语言:ANS ...

  2. wex5 教程 之 图文讲解 后台管理界面设计与技巧

    视频教程地址:http://v.youku.com/v_show/id_XMTgwOTAyMTkyMA==.html?from=s1.8-1-1.2&spm=a2h0k.8191407.0.0 ...

  3. How to use usercontrol - pass paramters

    在线PhotoShop http://uupoop.com/ In the previous chapter we created a UserControl, and now we will try ...

  4. php将抓取的图片链接下载到本地

    备注: fclose这一步操作完成之后如果返回值是空表示下载成功,否则会返回1或者其他错误提示 这个步骤测试的时候实在yii2框架的基础上执行的,下载到的图片实在frontend目录下的web目录下( ...

  5. Prince2是怎么考试的?

    Prince2是怎么考试的? 在前几年,对于项目经理来讲关注的很多是单项目管理的工具技术模板,谈论最多的是,进度延期,成本超支,范围蔓延等等!有一个不成文的形态就是--去考个PMP吧!一时间PMP成为 ...

  6. Cookie与Session的区别

    cookie机制 Cookies是服务器在本地机器上存储的小段文本并随每一个请求发送至同一个服务器.IETF RFC 2965 HTTP State Management Mechanism 是通用c ...

  7. JavaEE程序员必读图书大推荐

    下面是我根据多年的阅读和实践经验,给您推荐的一些图书: 第一部分: Java语言篇 1 <Java编程规范> 星级: 适合对象:初级,中级 介绍:作者James Gosling(Java之 ...

  8. Scrum Meeting 2-20151202

    任务安排 姓名 今日任务 明日任务 困难 董元财 完成下拉刷新的实现 请假(明天是编译截至最后一天) 无 胡亚坤 完成圆形头像代码设计 请假(明天是编译截至最后一天) 无 刘猛 学习listview的 ...

  9. LINUX CP 跳过询问是否覆盖

    有两个方法可以解决此问题: 1..bashrc里面注释掉 Alias cp='cp -i' 2.使用 \cp 命令(在cp前加一个'\')

  10. std::vector介绍

    vector是C++标准模板库中的部分内容,它是一个多功能的,能够操作多种数据结构和算法的模板类和函数库.vector之所以被认为是一个容器,是因为它能够像容器一样存放各种类型的对象,简单地说,vec ...