Insert with `r <code> ` withion markdown text to add r output in rmarkdown document.
Ex:
---
title: "Rmarkdown Parameters"
output: pdf_document
---
# Markdown document - `r example`
```{r}
example <- "This is an example document"
```
Ex:
---
title: "Rmarkdown Parameters"
output: pdf_document
---
# Markdown document - `r example`
```{r}
example <- "This is an example document"
```