title: python pandas plot with uneven timeseries index (with count evenly distributed)
body: <p>My dataframe has uneven time index.</p>
  
  <p>how could I find a way to plot the data, and local the index automatically? I searched here, and I know I can plot something like </p>
  
  <pre><code>e.plot()
  </code></pre>
  
  <p><img src="https://i.stack.imgur.com/8csJN.png" alt="even time"></p>
  
  <p>but the time index (x axis) will be even interval, for example per 5 minutes.
  if I have to 100 data in first 5 minutes and 6 data for the second 5 minutes, how do I plot 
  with number of data evenly. and locate the right timestamp on x axis.</p>
  
  <p>here's even count, but I don't know how to add time index.</p>
  
  <pre><code>plot(e['Bid'].values)
  </code></pre>
  
  <p><img src="https://i.stack.imgur.com/UEkGl.png" alt="even count"></p>
  
  <p>example of data format as requested</p>
  
  <p>Time,Bid</p>
  
  <p>2014-03-05 21:56:05:924300,1.37275</p>
  
  <p>2014-03-05 21:56:05:924351,1.37272</p>
  
  <p>2014-03-05 21:56:06:421906,1.37275</p>
  
  <p>2014-03-05 21:56:06:421950,1.37272</p>
  
  <p>2014-03-05 21:56:06:920539,1.37275</p>
  
  <p>2014-03-05 21:56:06:920580,1.37272</p>
  
  <p>2014-03-05 21:56:09:071981,1.37275</p>
  
  <p>2014-03-05 21:56:09:072019,1.37272</p>
  
  <p>and here's the link
  <a href="http://code.google.com/p/eu-ats/source/browse/trunk/data/new/eur-fix.csv" rel="noreferrer">http://code.google.com/p/eu-ats/source/browse/trunk/data/new/eur-fix.csv</a></p>
  
  <p>here's the code, I used to plot</p>
  
  <pre><code>import numpy as np
  import pandas as pd
  import datetime as dt
  e = pd.read_csv("data/ecb/eur.csv", dtype={'Time':object})
  e.Time = pd.to_datetime(e.Time, format='%Y-%m-%d %H:%M:%S:%f')
  e.plot()
  
  f = e.copy()
  f.index = f.Time
  x = [str(s)[:-7] for s in f.index]
  ff = f.set_index(pd.Series(x))
  ff.index.name = 'Time'
  ff.plot()
  </code></pre>
  
  <p><strong>Update</strong>: </p>
  
  <p>I added two new plots for comparison to clarify the issue. Now I tried brute force to convert timestamp index back to string, and plot string as x axis. the format easily got messed up. it seems hard to customize location of x label.</p>
  
  <p><img src="https://i.stack.imgur.com/sQ7KZ.png" alt="By ticks or data points"></p>
  
  <p><img src="https://i.stack.imgur.com/aJn17.png" alt="By time"></p>