title: Margin adjustments when using ggplot's geom_tile()
body: <p>From the documentation for ggplot2's <a href="https://web.archive.org/web/20120915004110/http://had.co.nz:80/ggplot2/geom_tile.html" rel="nofollow noreferrer">geom_tile()</a> function, we have the following simple plot:
  <a href="https://i.stack.imgur.com/XWxwU.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/XWxwU.png" alt="alt text"></a></p>
  
  <pre><code># Generate data 
  pp &lt;- function (n,r=4) { 
      x &lt;- seq(-r*pi, r*pi, len=n) 
      df &lt;- expand.grid(x=x, y=x) 
      df$r &lt;- sqrt(df$x^2 + df$y^2) 
      df$z &lt;- cos(df$r^2)*exp(-df$r/6) 
      df 
  } 
  p &lt;- ggplot(pp(20), aes(x=x,y=y)) 
  
  p + geom_tile()
  </code></pre>
  
  <p>How do I remove the margins that border the tile?  I have dug through this <a href="https://web.archive.org/web/20120803015755/http://had.co.nz:80/ggplot2/book/polishing.r" rel="nofollow noreferrer">script on polishing plots</a> for some hints to no avail.  I have found how to remove the background panels using opts(panel.background=theme_blank()), but not how to change the margin size.</p>