数据分析用R语言非常便捷,因为R语言的社区强大,并且在不断更新和完善,提供了各种分析利器。Knitr和Rmarkdown包则是数据分析中的动态报告利器。
下面是一份输出HTML文档的Rmd文件。备忘。
---
title: "Rmarkdown HandBook"
author: "Cheng"
date: "2016年9月4日"
output:
html_document:
toc: yes
number_sections: yes
---
本文档主要简述Rmarkdown的基本用法。
***
# Markdown语法
采用的是Markdown语法,需要快速浏览,[可以看](http://rmarkdown.rstudio.com/lesson-8.html)
插入链接
[R Project](www.r-project.org/)
R Logo:![](https://www.r-project.org/Rlogo.png)
无序列表
* unordered list
* item 2
有序列表
1. ordered list
2. item 2
***
# 基本用法
输出html,docx,pdf
需要编辑编辑YAML表头
## 选择输出格式
分别是html、pdf、docx、beamer幻灯片(pdf)、ioslides幻灯片(html):
output: html_document html