24

How can I export Jupyter notebooks to LaTeX? I can convert to PDF through LaTeX using the inbuilt menus but I'm unsure how to step in at the intermediate step and extract the actual LaTeX file.

Jakub Narębski
  • 309,089
  • 65
  • 217
  • 230
J-S
  • 973
  • 2
  • 8
  • 13

2 Answers2

31

You have to do this from the command line rather than the web interface with the following command:

jupyter nbconvert /path/to/mynotebook.ipynb --to latex

J-S
  • 973
  • 2
  • 8
  • 13
3

Anaconda Navigator provides JupyterLab. Use this to open jupyter notebook.

Under File menu you can find an item "Export Notebook As...".

This provides format such as Asciidoc, HTML, latex, pdf, Markdown, etc. You can choose your desired format.

  • +1 Just note that you don't need to use Anaconda Navigator for this; any way of installing JupyterLab should work. Just be sure to install `pandoc` as well. – Mike Sep 30 '22 at 14:52