put_gap: Insert a gap or whitespace in a document.

Description Usage Arguments Details Value Examples

View source: R/put_gap.R

Description

Creates white space in a document by creating an empty plot in ggplot2. Border and fill can be specified to create a box. The defaults are transparent.

Usage

1
put_gap(col = NULL, fill = NULL)

Arguments

col

Border color, default is "transparent"

fill

Fill color, default is "transparent"

Details

Allows the author of Rmd to docx documents to insert a vertical white space of specified height, particularly useful in creating documents that users are expected to write in, such as workshop or student lab materials.

The dimensions of the gap are determined when it is printed, e.g., using knitr in an R Markdown script, the box height in inches is set with the fig.height code chunk option.

Value

Prints the box to the output document.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
put_gap()
put_gap(col = "gray")
put_gap(col = "black", fill = "gray")

## Not run: 
# In an R Markdown script
```{r fig.height = 0.75}
put_gap()
```
## End(Not run)

docxtools documentation built on July 2, 2020, 3:16 a.m.