Building our presentation with R Markdown

In this section, we will develop our presentation's R Markdown file. We create an empty file named presentation.R and put the following headers in. The quotation marks are not required unless you want to include a colon in the title. As shown in a previous section, using backticks (“ ’), we can execute R code. In this case, we put the current date automatically in the front page. Finally, we chose ioslides_presentation as an output format. Feel free to experiment with the other outputs shown previously:

---
title:  "The Food Factory"
author: "Weekly Update"
date:   "`r Sys.Date()`"
output: ioslides_presentation
---

The following code sets up the default configuration for the code chunks in our presentation. ...

Get R Programming By Example now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.