1. R Installation
Usually under terminal directly apt-get can, in 16.10 get to R-3.3.1, at present the latest seems to be R-3.4.2, can go to the official website to download source code compilation (https://www.r-project.org)?
sudo Install R-base
2. Configuring R's kernel in Jupyter notebook
Recently ran Python under Jupyter, easy to debug while taking notes. Because Jupyter also supports the R language, try adding r kernel to Jupyter. Mainly relies on the "Irkernel" package. (Some packages may need FQ to download, the specific method please DIY.) The configuration method is as follows:
(1) Install the necessary Lib
sudo Install libzmq3-dev libssl-dev libcurl? 4-openssl-devsudo R # into the R environment?
>? Install.packages (C (' repr ', ' irdisplay ', ' Evaluate ', ' crayon ', ' pbdzmq ', ' devtools ', ' uuid ', ' Digest '))
Note: you will be prompted to select mirrors, we recommend selecting 0-cloud
> Devtools::install_github ('irkernel/irkernel');? Irkernel::installspec ()
If displayed, the following results indicate that the configuration was successful.
[Installkernelspec] Installed Kernelspec ir in/home/xxx/.local/share/jupyter/kernels/ir?
Note: Be sure to set the mirror when loading the R package on Jupyter, otherwise it will fail:
# Use the following command to set the image, such as I choose the mirror USTCoptions (repos = ' http://mirrors.ustc.edu.cn/CRAN/')# Check if the image changes GetOption ( ' Repos ')
Ubuntu-16.04 R Installation and Jupyter notebook configuration