>>>>> "Gerrit" == Gerrit Holl <ge...@nl...> writes:
Gerrit> Hi, to plot against dates, I use 'plot_date'. to plot
Gerrit> bars, I use 'bar'. How do I plot with bars against dates?
The key point is that all date plotting is converting your dates to
matplotlib datenums -- see num2date and date2num, and then setting the
tick locators and formatters properly so that they do the right thing.
To learn about tick locators and formatters see
http://matplotlib.sf.net/matplotlib.ticker.html and in a date specific
contect http://matplotlib.sf.net/matplotlib.dates.html .
Once you have digested that, take a look at the plot_date
implementation in axes.py. Basically all it does is try to make an
intelligent guess about which locator and formatter to use, and then
forwards to data to "plot".
So all you have to do is make the intelligent choice about locator and
formatters yourself, and send the date2num data directly to bar.
(nice signature, btw)
JDH
|