title: R - Boxplot with median values temperature coloured
body: <p>I have a boxplot for 39 species and the annual temperature values of their distribution range (<code>bio01</code>). The median values are in row 3 of the <code>boxplot$stats</code>. I want to color the highest median value red and the lowest blue, i.e. a temperature gradient. The code below for <code>medcol</code> is not working. Can somebody suggest a solution?</p>
  
  <pre><code>b &lt;- boxplot(bio01 ~ species, data=species.threshold.22.climate.751, las=2, ylab ="bio01", par(mar = c(18, 5,5, 2)+ 0.1), cex.names=0.2, bw = 5, medcol=b$stat[3,])
  b$stats
  </code></pre>