title: Change histogram bar colours greater than a certain value
body: <p>So far, I've managed to change the colour a single bar in a histogram following the example <a href="https://stat.ethz.ch/pipermail/r-help/2008-October/178206.html" rel="noreferrer">here</a></p>
  
  <pre><code>test &lt;- rnorm(100);
  h &lt;- hist(test);
  b &lt;- cut(1, h$breaks);
  clr &lt;- rep("grey", length(h$counts));
  clr[b] &lt;- "red";
  plot(h, col=clr);
  </code></pre>
  
  <p>I want to be able to change the colour of histogram bins that are above a certain x-axis value - e.g. that are above 1 in the distribution function in the example. Part of the reason why I am having trouble is that I don't exactly understand the factor that <code>cut()</code> returns.</p>