Create Chinese Beamer & PDF with rmarkdown
on Windows.
Must have installed MikTex 2.9
and pandoc 1.15
. To test whether have installed pandoc
,just run pandoc -v
in the Windows Cmd (win+R -> cmd ->Enter).
- tinytex: https://yihui.name/tinytex/
- download this repository
- open the
test.Rmd
- press Ctrl + Shift + K (knit PDF)
- wait a minute and see what has been generated.
Just click new R Markdown -> presentation -> PDF(Beamer). Edit the file, then press knit. If you haven't run the code before, it wil take about 2minutes to render Rmd to PDF.
Notice: the beamer_default.tex
& _output.yaml
& the Rmd file should be in the same fold!
You can also customise the beamer theme in the Output Options
, which next to knit PDF
. Or you can directly change default theme and fonttheme in the _output.yaml
file.
If you encounter a problem, please don't hesitate to creat an issue. You'd better print the error info.
Beamer.pdf,Here are the snapshots:
- the Rmd file is in the
Chinese-PDF
fold - open the
code.Rmd
- press Ctrl + Shift + K (knit PDF)
- you will encounter
43
error.
Notice: it's because that your MikTex lacks some related packages. So you need to open the default.latex
and the MikTex Packages Manager
to download the packages that are used in the default.latex
.
I don't know how many times I have tried, but it worked at last. Good luck, my friend!
Chinese.pdf, Here are the snapshots:
Licensed under theApache License, Version 2.0.