环境:
- os: centos7
- R: 3.4.2
- jupyter: 4.4.0
坑预告
- R中无法安装git2r, devtools
- IRkernel::installspec()找不到jupyter
安装准备
确保下面这些工具已经被安装在系统中
安装步骤
1.一定要sudo进入R
2.先试试git2r能不能安装成功
不过不行的话,退出R, 在外边下载安装git2r
3.在sudo回到R下,按照官网文档的步骤做。
如果提示”jupyter-client has to be installed but “jupyter kernelspec –version” exited with code 127.”。那么需要把已经安装好的jupyter链接到/usr/bin下,使R可以比较方便地找到jupyter
“/home/pyy/tool/anaconda3/bin/jupyter”是我的jupyter的完整路径
结果
最后,打开jupyter-lab里就自动出现R kernel了