如何在jupyter中编写LaTeX(不仅仅是方程)

问题描述 投票:0回答:3

可以用jupyter写LaTeX吗?看起来

IPython.display.Latex
只支持 LaTeX 方程的一个子集。我特别想使用
\tabular
和其他 LaTeX 命令(
HTML
不是一个选项)。

latex jupyter
3个回答
2
投票

您应该查看 https://github.com/ipython-contrib/IPython-notebook-extensions 中的 Latex_envs 扩展(从此存储库安装,它是最新版本 - 请按照自述文件中的说明进行操作) )。这里有一些文档https://rawgit.com/jfbercher/latex_envs/master/doc/latex_env_doc.html


0
投票

我最近在 Jupyter Lab 尝试过这个。将单元格标记为“原始”。然后:

   %%latex

  \bf{This is a test} \\
 It allows latex $\alpha=\beta$ and test:

 \begin{equation}
 \alpha = \beta
 \end{equation}
 % this is a latex comment

然后文件 -> 将笔记本导出为 -> PDF


0
投票

使用蟒蛇。在作为 Anaconda 一部分的 Jupyter Notebook 中,您可以简单地使用 $latex_code$ 进行内联或 $$latex_code$$ 进行显示。

© www.soinside.com 2019 - 2024. All rights reserved.