jupyter notebook 目录配置、导出 tex 和 pdf 及中文支持
环境:macbook pro, mactex, jupyter notebook, brew
安装pandoc从而支持格式转换为tex:
brew install pandoc
修改tex article 模板,添加中文支持:
find / -name 'article.tplx' >/dev/null | xargs vi
# like .../nbconvert/templates/latex/article.tplx
# 或者分两条命令运行
修改Latex Article头部为:
%===============================================================================
% Latex Article
%===============================================================================
((* block docclass *))
\documentclass[11pt,adobefonts,fancyhdr,hyperref,UTF8]{article}
\usepackage{fontspec, xunicode, xltxtra}
\usepackage{ctex} %中文支持
\setCJKmainfont{苹方-简} %中文字体
((* endblock docclass *))
(notebook标题似乎仍然不支持中文)
然后在jupyter notebook中直接下载为 pdf via LaTex即可自动得到pdf文件。或者下载为 latex(.tex) 再用 texshop -> xlatex 编译 亦可。
PS1: mark down 新手指南
PS2:jupyter notebook 设置默认目录方法
关闭notebook, 然后运行:
jupyter notebook --generate-config # 生成config 文件, like /Users/xxx/.jupyter/jupyter_notebook_config.py
修改jupyter_notebook_config.py文件中 c.NotebookApp.notebook_dir 配置行:
## 用于笔记本和内核的目录。
c.NotebookApp.notebook_dir = '/Users/xxx/Projects/jupyter_workspace'
重启notebook即可
jupyter notebook 目录配置、导出 tex 和 pdf 及中文支持的更多相关文章
- jupyter notebook 安装配置使用,+目录插件安装
1.安装 pip3 install jupyter 2.配置 2.1. 生成一个 notebook 配置文件 jupyter notebook --generate-config /root/.jup ...
- jupyter notebook——安装配置
本地登陆 cmd输入下面的命令,会进入用户主目录 jupyter notebook 在浏览器打开时,提示输入token,复制命令行上的token还是不能进入,其实浏览器上有提示的,按照提示操作即可,输 ...
- Jupyter Notebook的配置(密码端口+远程登陆+nbextension)
1 生成配置文件 linux和mac系统打开终端 windows系统打开anaconda自带的终端 jupyter notebook --generate-config 此时系统会生成 ~/.jupy ...
- jupyter notebook远程配置
服务器端配置 在服务器生成jupyter配置文件 $jupyter notebook --generate-config 生成之后会得到配置文件的路径 启动jupyter,设置密码 In [1]: f ...
- windows远程访问ubuntu下的jupyter notebook必要配置
0.生成配置文件(一般采用默认) jupyter notebook --generate-config 1.打开ipython, 创建一个密文密码 In [1]: from notebook.auth ...
- anaconda+jupyter notebook 安装配置
安装Anaconda 从清华大学开源软件镜像站选择合适自己的版本 wget https://mirrors.tuna.tsinghua.edu.cn/anaconda/archive/Anaconda ...
- [Mac][Python][Jupyter Notebook]安装配置和使用
Jupyter 项目(以前称为 IPython 项目),提供了一套使用功能强大的交互式 shell 进行科学计算的工具,实现了将代码执行与创建实时计算文档相结合. 这些 Notebook 文件可以包含 ...
- Ubuntu-16.04 R 安装及Jupyter notebook 配置
1. R 安装 通常在Terminal下直接apt-get 即可,在16.10下可以get到R-3.3.1,目前最新好像是 R-3.4.2,可以去官方网站下载源码编译 (https://www.r-p ...
- Jupyter Notebook的安装
依赖安装 pandoc texlive-xetex texlive-lang-cjk 安装Jupyter Notebook 本文不讲解在Anaconda中安装. 安装方法 sudo python -m ...
随机推荐
- [Leetcode 40]组合数和II Combination Sum II
[题目] Given a collection of candidate numbers (candidates) and a target number (target), find all uni ...
- 机器学习 xgboost 笔记
一.数据预处理.特征工程 类别变量 labelencoder就够了,使用onehotencoder反而会降低性能.其他处理方式还有均值编码(对于存在大量分类的特征,通过监督学习,生成数值变量).转换处 ...
- 最近工作再弄基于bootstrap的定制sass
封装各种组件如 button table 当然..我只才做完两个. 比如table 抽出很多类以后可以配置的值 还有button 目录结构大致是 scss主要css文件 base和components ...
- vue安装遇到vue不是内部变量
配置path系统变量 打开我的电脑-->右键属性-->高级系统设置-->环境变量-->Path-->添加获得npm的位置(搜索vue.cmd 可以找到该位置) 全局安装位 ...
- [git]入门-创建版本库
转载整理自:https://www.liaoxuefeng.com/wiki/0013739516305929606dd18361248578c67b8067c8c017b000/0013743256 ...
- 【SoftwareTesting】Homework2
For the Program1, For Question1: The fault is that in the loop condition, ' i ' should be not less t ...
- BluePrism初尝2
在接近三周的自学中,初步体验到了RPA的甜头. 在对BP这个工具慢慢的深入接触中,从0 到1的探索式学习,从最开始的一个个的小功能模块的用途,每一个的属性的功能,到现在自己能初步尝试组织一些简单的流程 ...
- 信息技术手册可视化进度报告 基于BeautifulSoup框架的python3爬取数据并连接保存到MySQL数据库
老师给我们提供了一个word文档,里面是一份信息行业热词解释手册,要求我们把里面的文字存进数据库里面,然后在前台展示出来. 首先面临的问题是怎么把数据导进MySQL数据库,大家都有自己的方法,我采用了 ...
- L364 Should Your Resume Be One Page or Two?
Should Your Resume Be One Page or Two? Conventional wisdom suggests that you should keep it short: A ...
- myls
#include <stdio.h> #include <sys/types.h> #include <sys/stat.h> #include <unist ...