title: geom_tile - draw empty tiles
body: <p>I want to draw a black border for every tile even though my data set is  missing values for some combinations of x and y</p>
  
  <pre><code>library(dplyr)
  set.seed(10)
  df = data.frame(x=factor(sample(1:5, 5)), y=factor(sample(1:5, 5)), z=factor(sample(1:5, 5)))
  ggplot(df, aes(x=x, y=y, fill=z)) + geom_tile(size=0.5, color="black") 
  </code></pre>
  
  <p><a href="https://i.stack.imgur.com/D2GiH.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/D2GiH.png" alt="enter image description here"></a></p>
  
  <p>It will work if I fill NA for the missing xy values. Also, the legend now shows the "NA" label, which I want to hide.</p>
  
  <p>Is there a way to draw every tiles without filling in NA?</p>
  
  <pre><code># fill in NA for missing combinations of x and y before drawing geom_tile
  df2 = df %&gt;% complete(x,y)
  ggplot(df2, aes(x=x, y=y, fill=z)) + geom_tile(size=0.5, color="black") + scale_fill_brewer(palette="Set1", na.value="white")
  </code></pre>
  
  <p><a href="https://i.stack.imgur.com/MNb0D.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/MNb0D.png" alt="enter image description here"></a></p>