On Wed, Mar 25, 2009 at 3:25 PM, Tyler B <[email protected]> wrote:
>
> And yet here is the result: http://screencast.com/t/gLPDFtwnJM4
>
> I can't figure out why the values are 'grouping' around particular values
> on the x-axis... I would expect it to look more like a function, with only
> one y-value for each x.
>
I am not seeing the problem when I run your script with your datafile (there
is no grouping in columns like you have; instead I get a distinct x for each
date). I wonder if you have an old dateutil or an old matplotlib.
With recent matplotlib, you can do with less code::
import matplotlib.cbook as cbook
import matplotlib.mlab as mlab
import matplotlib.pyplot as plt
r = mlab.csv2rec('gmail-count.txt', names='date,val1,val2',
converterd={'date' : cbook.todatetime('%Y-%m-%d
%H:%M:%S')})
fig = plt.figure()
ax = fig.add_subplot(111)
ax.plot(r.date, r.val1, 'g^')
fig.autofmt_xdate ()
plt.show()
JDH
------------------------------------------------------------------------------
_______________________________________________
Matplotlib-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/matplotlib-users