title: How can I change the number of columns several times in an R Markdown pdf document?
body: <p>I am creating a .pdf using R Markdown. I would like to have a section of text in two column format, and then follow that with a graph (or table, photo, etc.) that takes up the entire width of the page, and then return to two column text.  I am new at Markdown / LaTex / Pandoc and I cannot figure out how to do it.</p>
  
  <p><a href="https://stackoverflow.com/a/39559033/2679518">This answer</a> by @AlisonShelton appears to be what I want, but when I run it I get this error in the RStudo R Markdown console:</p>
  
  <blockquote>
    <p>! Undefined control sequence.<br>
    l.87 \btwocol<br>
    pandoc.exe: Error producing PDF<br>
    Error: pandoc document conversion failed with error 43</p>
  </blockquote>
  
  <p>I have successfully used <a href="https://stackoverflow.com/a/34809186/2679518">this method</a> by @scoa to make a two column .pdf, but I don't know how go back and forth between one and two columns using this.</p>
  
  <p>Here is some sample code for testing purposes</p>
  
  <pre><code>    ---
      title: "Test"
      output: pdf_document
      ---
  
      ```{r setup, include=FALSE}
      knitr::opts_chunk$set(echo = TRUE)
      ```
  
      ## Two columns of text
  
      This seciton should be in two column format.
      Here are a bunch of ? to make it longer: ???????????????????????????????????????????????????????????????????????????????
      ????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????
      ??????????????????????????????????????????????????????????????????????????????????????????????????????????????????????
      ??????????????????????????????????????????????????????????????????????????????????????????????????????????????????
  
  ## Once column section. 
  This part should be the whole page width
  ```{r plot}
  plot(rnorm(20),rnorm(20))
  ```
  
  ## Now 2 columns again
  This section should go back to two columns  !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
  !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
  !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
  </code></pre>