Rmarkdown:输出pdf设置

输出pdf需要安装Ctex

---
title: "first markdown"
author: "name"
date: "`r format(Sys.time(), '%Y年%m月%d日')`"
geometry: left = 3.18cm, right = 3.18cm, top = 2.0cm, bottom = 2.0cm
fontsize: 12pt
output: 
        pdf_document: 
                latex_engine: xelatex
header-includes:
- \usepackage{xeCJK}
- \usepackage{graphicx}
- \usepackage{fancyhdr}
- \usepackage{setspace}
- \usepackage{indentfirst}
- \setmainfont{Times New Roman}
- \setCJKmainfont{Microsoft YaHei}
- \parindent 2 em
---
posted @ 2017-12-17 20:51  嘻呵呵  阅读(5432)  评论(0编辑  收藏  举报