# set global chunk options library(knitr); library(knitcitations) opts_chunk$set(cache=TRUE) opts_chunk$set(fig.path = 'assets/fig/<%= group %>-') #bib <- read.bibtex(file.path(getwd(), basename(getOption("bib.loc")))) #cite in text using `r citet(bib[1])`
Set the path to save figures to be unique for each of the reports; otherwise unnamed chunks will get overwritten.
heatmap(as.matrix(mtcars[mtcars$cyl == <%= group %>, ]))
After you've developed a template run the functions in the brew.R file located in the main directory.
Note: that you'd want to replace the pound signs in front of title, subtitle, and author and replace with a percent sign to use md2pdf
#bibliography("html")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.