|
From: John H. <jdh...@ac...> - 2005-02-04 15:50:44
|
>>>>> "Travis" == Travis Brady <td...@fa...> writes:
Travis> Hi Everyone, I'm using plot_date to scatter a ton of data
Travis> retrieved from a database and have encountered an error
Travis> with the date ticks.
Travis> I more or less copied the format of the example in
Travis> http://matplotlib.sourceforge.net/examples/date_demo2.py
Travis> and my ticks ended up being months in order but never
Travis> making it past the year 2001 (they just recycle) though my
Travis> data begin in 2000 and end in 2004.
Travis> I took another look at the plot generated by date_demo2.py
Travis> and it turns out that the same is true there.
Travis> I'm thinking this is not intentional, but if so does
Travis> anyone have any advice or example scripts that might help
Travis> me fix my plot?
That's because the format string is printing 'month day' and not
'month year' and the day is always 01 in the example. You might want
monthsFmt = DateFormatter("%b '%y")
Hope this helps,
JDH
|