I have many chunks in my documents some of them produce 2 plots side by side, some produce 3 plots side by side and some others are just for displaying results (among which some even echo out the code). I can set the global knitr option for the document as follows;
{r setup, include = FALSE, cache = FALSE}
knitr::opts_chunk$set(
comment = NA,
fig.width = 7,
out.width = 50%,
warning = FALSE
)
But I want to set up multiple sets of such global options, so that some target the figure chunks with double figure side by side and some target the result output.
Since the options are just a list, I can create multiple lists of various options, but I am wondering how can I include those options in those individual chunks?