使用Jupyter Lab进行幻灯片编辑

时间:2018-10-06 08:16:31

标签: python jupyter-notebook jupyter jupyter-lab

新的Jupyter Lab很不错,但是我缺少将单元格变成幻灯片的选项。在经典的Jupyter笔记本中,该文件位于“查看>单元格工具栏>幻灯片”下:

enter image description here

该功能发生了什么?在Jupyter Lab中可以编辑幻灯片吗?

3 个答案:

答案 0 :(得分:1)

在Jupyter Lab中,您可以在“单元格检查器”菜单中更改“幻灯片类型”。

答案 1 :(得分:1)

我在Ubuntu 18.04.3 LTS上安装了jupyter实验室1.1.4,并且正在使用python 3虚拟env内核,并且运行良好。只需完成您的笔记本,然后使用最左侧的“笔记本工具”选项卡配置每个单元(如屏幕截图所示)。然后保存并关闭笔记本,然后运行以下命令输出幻灯片。

enter image description here

打开终端并导航到最近保存的.ipynb并运行

jupyter nbconvert Untitled2.ipynb --to slides

幻灯片或说

jupyter nbconvert Untitled2.ipynb --to pdf

对于pdf

enter image description here

注意:您可能需要将Tex软件包安装到perfrom pdf输出中。请参阅文档here或仅运行以下命令进行安装。

sudo apt-get install texlive-xetex texlive-fonts-recommended texlive-generic-recommended

欢呼

答案 2 :(得分:0)

仍然可以使用nbconvert

Presenting Code Using Jupyter Notebook Slides

您需要运行的命令:

jupyter nbconvert jupyter_notebook.ipynb --to slides --post serve