title: How to get a newline in a figure caption in Rmarkdown bookdown pdf:document2
body: <p>I'm using knitr in RStudio to write an rmarkdown bookdown:pdf:document2 document.
  I have two plots, plotted side-by-side with gridExtra, and labelled A and B.  I want to put a newline in the output of the figure caption, as defined with fig.cap, between the caption for A and that for B, but I am stumped.  I have tried:</p>
  
  <p>\n - ignored as if it was not there</p>
  
  <p>\\n - undefined control sequence</p>
  
  <p>\\\n - Argument of @tempf has an extra }.</p>
  
  <p>\\\\n - prints "\n" (getting a bit silly here)</p>
  
  <p>double space - does nothing</p>
  
  <p>I even tried, out of desperation, HTML style newlines, which I can't figure out how to display here, but I didn't expect them to work and they didn't.</p>
  
  <p>It's possible in LaTeX so surely there is a way...</p>
  
  <p>NOTE: this is not a duplicate of <a href="https://stackoverflow.com/questions/33628318/split-r-chunk-header-across-lines-in-knitr">Split r chunk header across lines in knitr</a> as that is asking how to split a long caption in a chunk header across lines in the <em>code</em>, and I am asking how to do so in the <em>output</em>.</p>
  
  <p>Susannah</p>
  
  <pre><code>---
  title: "MRR captions"
  author: "Susannah Cowtan"
  date: "14 December 2018"
  output:
    bookdown::pdf_document2:
      citation_package: natbib
      number_sections: no
      toc: no
      keep_tex: true
    bookdown::html_document2: null
  header-includes: 
  - \usepackage{float}
  - \usepackage{booktabs}
  fontsize: 11pt
  papersize: A4
  ---
  
  ```{r knitr_setup, include=FALSE}
  knitr::opts_chunk$set(echo = FALSE)
  ```
  
  ```{r plot-mtcars, fig.height = 3, fig.width = 4, fig.cap = "A: foo bar baz \nB: foobar"}
  plot(mpg ~ wt, data = mtcars)
  ```
  </code></pre>