title: How to print or cat text into pdf() in R without markdown
body: <p>I'm creating a PDF file with some plots, but I want to also include some text message at the bottom. For reasons beyond my control, I cannot install a latex distribution on this system, so I can't knit a markdown file, but have to use <code>pdf()</code>.</p>
  
  <p>When I just use <code>print</code> or <code>cat</code> nothing shows up in the pdf. I tried using <code>sink()</code> based on the answer from <a href="https://stackoverflow.com/questions/51940526/print-text-message-to-pdf-from-r">here</a>, but that didn't work either:</p>
  
  <pre><code>pdf("filename.pdf")
  sink("filename.pdf")
  print("message")
  sink()
  dev.off()
  </code></pre>
  
  <p>No error message was received, but the file created has no pages.</p>
  
  <p>Any ideas? I'm considering a workaround of just plotting a text only plot, but I'm hoping there's a more reasonable solution.</p>