R Markdown

Table of Contents

Overview

Reference

```{r chunk_name, option=value, ...}

How-to

Put current date in the YAML meta header howto

date: "`r format(Sys.time(), '%d %B, %Y')`"

Run a livereloaded R Markdown webserver howto

install.packages('servr')
Rscript -e "servr::rmdv2()" -b
#                            +-- open a web browser

servr tries to use make if Makefile exists in the working directory.

Cache objects within explicit environments in R Markdown howto

e <- new.env()
with(e, {
  # Do things which take a long time
})
# NOTE: Let `knitr` cache the environment
e = e