title: Adding colored boxes to axes in Python's matplotlib
body: <p>Community,</p>
  <p>Say I have created a scatter plot with Python's matplotlib:</p>
  <pre><code>plt.scatter(x, y)
  </code></pre>
  <p>Let's say this is the data:
  <a href="https://i.stack.imgur.com/nLmpJ.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/nLmpJ.png" alt="enter image description here" /></a></p>
  <p>Now, is there a way to add colored boxes on the axis (between given x-values, e.g.,: add a green box from x=-0.2 to x=0, add a ...) like this:
  <a href="https://i.stack.imgur.com/CjDUe.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/CjDUe.png" alt="enter image description here" /></a></p>
  <p>Including the text labels (at the mid-range I guess).</p>
  <p>I am not even sure how to get started on this one to be honest (besides making the scatter plot).</p>
  <p><strong>Question</strong>
  Can anyone at least direct me to a feature of matplotlib that does this (or any other Python package)?</p>
  <p>Your help is much appreciated.</p>