官网手册位于https://cloud.r-project.org,是个单页应用,位置不好找:
Ubuntu 16.04.6 LTS的默认源中没有R,因此首先在/etc/apt/sources.list最后一行增加R的源:
1 |
deb https://cloud.r-project.org/bin/linux/ubuntu disco-cran35/ |
然后执行:
1 2 |
sudo apt-get update sudo apt-get install r-base |
即可。安装完成后,直接输入R命令即可启动:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 |
root@hadoop001:~/spark-2.4.4-bin-without-hadoop-scala-2.12# R R version 3.4.4 (2018-03-15) -- "Someone to Lean On" Copyright (C) 2018 The R Foundation for Statistical Computing Platform: x86_64-pc-linux-gnu (64-bit) R is free software and comes with ABSOLUTELY NO WARRANTY. You are welcome to redistribute it under certain conditions. Type 'license()' or 'licence()' for distribution details. Natural language support but running in an English locale R is a collaborative project with many contributors. Type 'contributors()' for more information and 'citation()' on how to cite R or R packages in publications. Type 'demo()' for some demos, 'help()' for on-line help, or 'help.start()' for an HTML browser interface to help. Type 'q()' to quit R. > |
转载时请保留出处,违法转载追究到底:进城务工人员小梅 » Ubuntu 16.04.6 LTS安装R 3.6