markdown转为pdf文档---Rmarkdown
Typora可以输出Pdf,但是样式并不够好看,尤其是没有页码的概念,转化出的tex再编译,代码高亮方式也不太合适。 那么,Rmarkdown要更好一些。 只需要在md文件前填写一些记录,再改为rmd的后缀,用knit编译即可。 插入代码时,代码段使用 ```python ``` 不要使用大括号,那会在编译文档过程中运行代码。 --- title: "markdown2pdf" output: pdf_document: toc: true toc_depth: 2 fig_width: 7 fig_height: 6 fig_caption: true df_print: kable highlight: tango latex_engine: xelatex citation_package: biblatex keep_tex: true --- 效果 GBoost = GradientBoostingRegressor(n_estimators=600, learning_rate=0.05, max_depth=4, max_features='auto', min_samples_leaf=15, min_samples_split=5, loss='huber', random_state =5) 参考:谢益辉的Rmarkdown包文档。 来源: https:/