title: Rasterize plot when using PDF output device
body: <p>Hello everybody out there using R,</p>
  
  <p>When putting multiple plots with thousands of data points into a single PDF file, this file can get huge and take a long time to open.</p>
  
  <p>The following post describes exactly the same problem in Matplotlib, as well as a nice fix for it:
  <a href="https://stackoverflow.com/questions/22771693/matplotlib-multipage-pdf-with-rasterized-plots">Matplotlib: multipage PDF with rasterized plots</a>
  Particularly nice about it is, that it only rasterizes the points without rasterizing the labels.
  <a href="http://www.astrobetter.com/blog/2014/01/17/slim-down-your-bloated-graphics/" rel="nofollow noreferrer">http://www.astrobetter.com/blog/2014/01/17/slim-down-your-bloated-graphics/</a> contains a nice example of it.</p>
  
  <p>I am now looking for a similar solution in R.</p>