title: Percentiles on X axis with matplotlib
body: <p>I have a sorted numpy array of floats that I want to plot. I would like to print percentiles on the x axis. I know how to get the percentile values.</p>
  
  <p>Here is what I have, but I don't know what to do with my array of percentile values:</p>
  
  <pre><code>import numpy as np
  import pylab as P
  import matplotlib as mp
  
  d = np.loadtxt("report.stats.sorted")
  pct = mp.mlab.prctile(d, p=(0.0, 10.0, 25.0, 50.0, 75.0, 90.0, 100.0))
  
  P.plot(d)
  P.show()
  </code></pre>
  
  <p>The plot shows a nice curve but the x axis is showing ticks with the number of entries. What I want is ticks showing [0.0, 25.0, 50.0, 75.0, 100.0] at the appropriate location.
  <img src="https://i.stack.imgur.com/OPaNV.png" alt="enter image description here">
  Sorry if it's not clear.</p>