title: Using geom_boxplot with facet_grid and free_y
body: <p>This question has been asked <a href="https://stats.stackexchange.com/questions/11406/boxplot-with-respect-to-two-factors-using-ggplot2-in-r">a</a> <a href="https://stackoverflow.com/questions/21937127/different-axis-limits-per-facet-in-ggplot2">few</a> <a href="https://stackoverflow.com/questions/10735539/ggplot2-boxplot-with-facet-grid-and-free-scale">times</a>, but I've read them all and cannot find an answer.</p>
  
  <pre><code>df &lt;- data.frame(f1=factor(rbinom(100, 1, 0.45), label=c("m","w")), 
                   f2=factor(rbinom(100, 1, 0.45), label=c("young","old")),
                   boxthis=rnorm(100))
  ggplot(aes(y=boxthis, x=f2), data=df) 
    + geom_boxplot() 
    + facet_grid(~f1, scales="free")
  </code></pre>
  
  <p>This generates the plot below, but <strong>the y axis is shared across the facet column</strong>. In my real data, this is a problem as each factor in <code>f1</code> needs a widely different axis range. Is there some trick to getting <code>free</code> to work here? </p>
  
  <p><img src="https://i.stack.imgur.com/JdVPv.png" alt="plot"></p>
  
  <p>I have found that <code>free</code> works as expected when making the facet vertical, as shown below, but this clearly looks horrid compared to making the facet horizontal</p>
  
  <pre><code>ggplot(aes(y=boxthis, x=f2), data=df) 
    + geom_boxplot() 
    + facet_grid(f1~., scales="free")
  </code></pre>
  
  <p><img src="https://i.stack.imgur.com/leBiz.png" alt="plot2"></p>