title: Inserting new lines into kable headers
body: <h3>Problem description:</h3>
  
  <p>I'm writing a document in rMarkdown and I need to format a table before producing a PDF. The issue is that I'm having trouble inserting a new line in my <code>kable</code> headers that have been added using the <code>add_headers_above</code> command.</p>
  
  <p>Currently the text "Month (persons)" - which is the first header added with that command - appears as one line. I'd like to break that so that a new line is inserted between "Month" and "(persons)".</p>
  
  <p>The motivation is simply to save horizontal page space so that I can fit two tables size by size on one A4 sheet.</p>
  
  <h3>My attempt at the fix</h3>
  
  <p>I've tried to include <code>\n</code> in the <code>add_headers_above</code> command:</p>
  
  <p><code>[...] %&gt;%
      add_header_above(c(" ", 'Month \n (persons)' = 1, "TTY  \n (persons)" = 1, "TTY \n (% chg.)" = 1))
  </code>
  But that hasn't worked.</p>
  
  <h3>Reproducible example:</h3>
  
  <pre><code>---
  output: pdf_document
  ---
  
  ```{r setup, include=FALSE}
  knitr::opts_chunk$set(echo = TRUE)
  library(knitr)
  library(kableExtra)
  library(tibble)
  ```
  ```{r}
  df &lt;- tribble(~Location, ~Jan_Qrt, ~Jan_year, ~growth,
  "New South Wales",  16000,  403300,       3.30,
  "Victoria",        -21200,    134100,       3.50,
  "Queensland",        2100,  100200,       3.20,
  "South Australia",  19700,  117900,       5.00,
  "Western Australia",   5300,   13200,     1.60,
  "Tasmania",         -8900,   24300,     1.90,
  "Northern Territory",    -400,    5700,    2.40,
  "Australian Cap",     300,   -4300,    -3.10,
  "Australia",         800,   10600,     4.80)
  
  kable(df, format = 'latex', booktabs = T, align = 'r') %&gt;%
    kable_styling(full_width = F, font_size = 8) %&gt;%
    row_spec(row = 9, bold = TRUE) %&gt;%
    add_header_above(c(" ", 'Month (persons)' = 1, "TTY (persons)" = 1, "TTY (% chg.)" = 1))
  
    ```
  </code></pre>