title: Shade (fill or color) area under density curve by quantile
body: <p>Suppose e.g. I want to shade the area under the density curve for the standard normal distribution  by <em>decile</em>. I want the left-most 10% of the area to have a different shading to the next 10% and so on.</p>
  
  <p>This is a variant on the questions "<a href="https://stackoverflow.com/questions/3494593/shading-a-kernel-density-plot-between-two-points">Shading a kernel density plot between two points</a>" and "<a href="https://stackoverflow.com/questions/20355849/ggplot2-shade-area-under-density-curve-by-group">ggplot2 shade area under density curve by group</a>", but I want to shade <em>each</em> quantile (in my example, each group is a decile but the process should easily generalise to other quantiles).</p>
  
  <p>I don't mind whether a solution uses <code>ggplot2</code> or <code>base</code> graphics, and whether this is done directly from a formula (which would be really neat) or based on making a data frame first. If the latter, you may want:</p>
  
  <pre><code>delta &lt;- 0.0001 
  z.df &lt;- data.frame(x = seq(from=-3, to=3, by=delta))
  z.df$pdf &lt;- dnorm(z.df$x)
  z.df$decile &lt;- floor(10*pnorm(z.df$x) + 1)
  </code></pre>
  
  <p>Note that the naive solution <code>ggplot(z.df, aes(x = x, fill = quantile)) + geom_ribbon(aes(ymin = 0, ymax = pdf))</code> would fail because <code>Aesthetics can not vary with a ribbon</code>.</p>