From: John H. <jdh...@ac...> - 2004-02-07 03:14:17
|
>>>>> "Peter" == Peter Groszkowski <pgr...@ge...> writes: Peter> plot(date_in_some_format, data) Are the dates strings, python datetime instances, mx datetime instances, or what? Here is a thread on python-list you may be interested in http://groups.google.com/groups?hl=en&lr=&ie=UTF-8&oe=UTF-8&threadm=mailman.766.1068941179.702.python-list%40python.org&rnum=1&prev=/groups%3Fq%3Dmatplotlib%2Bdate%26ie%3DUTF-8%26oe%3DUTF-8%26hl%3Den%26btnG%3DGoogle%2BSearch Peter> I suppose an alternative would be to convert the times to Peter> say seconds, create a plot and manually add the actual Peter> date/time label (text). This would be tedious but doable. Currently this is the best way. It would not be too much work to write a function called plotdate which took, for example, python2.3 datetime instances as the x arg, arbitrary y values, and a datetime format string as an optional arg, and did all the conversions for you, set the tick labels, etc... If you want to do it, I think it would be a nice addition to matplotlib. JDH |