如何使用R markdown在Word文档报告中创建网格表

时间:2016-11-15 02:21:55

标签: r knitr r-markdown pandoc pander

我能够使用R markdown生成一个包含简单表格的word文档报告,但我无法使用包含网格的表生成报告。

我尝试创建可重现的代码。

---
title: "Unable to create table having grids"
output: word_document
---

```{r setup, include=FALSE}
knitr::opts_chunk$set(echo = TRUE)
```

## R Markdown simple table

Tables             Are           Cool
-------------     -----------   -----------
col 3 is         right-aligned  $1600 
col 2 is         centered         $12 
zebra stripes    are neat         $1"


## Table Does Not have grids in it.

+--------------+---------------+---------+
|Tables        | Are           | Cool    |
+==============+===============+=========+
|col 3 is      | right-aligned | $1600   |
+--------------+---------------+---------+
|col 2 is      | centered      |   $12   |
+--------------+---------------+---------+

0 个答案:

没有答案