On Wed, Feb 8, 2012 at 10:24 AM, Ted To <rainexpec...@theo.to> wrote:

> On 02/08/2012 11:17 AM, John Hunter wrote:
> >
> >
> > On Wed, Feb 8, 2012 at 10:06 AM, Ted To <rainexpec...@theo.to
> > <mailto:rainexpec...@theo.to>> wrote:
> >
> >     If it hasn't been fixed, is there a workaround?
> >
> >     On 02/08/2012 10:42 AM, Ted To wrote:
> >     > I believe I have traced it to some axhline and axis commands and
> >     this is
> >     > apparently an old problem.  Does it work with version 1.1.0?  I
> have
> >     > 1.0.1 installed on a debian system.
> >
> >
> > Can you "print(dates)" before calling plot in the environment in which
> > it fails and post the output here.
> >
> > JDH
>
> Sure, the commands where it crashes and the output are:
>
> print dates
> pyplot.axis([0, len(prices.label[0]), -1.5, 1.5])
>



OK, here is where the problem is.  In the plt.axis call you are setting the
x-axis min to 0 which is not a legal date value.  I suggest letting the
x-axis take care of itself, and set the y-axis limits with

plt.ylim(-1.5, 1.5)

JDH
------------------------------------------------------------------------------
Keep Your Developer Skills Current with LearnDevNow!
The most comprehensive online learning library for Microsoft developers
is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,
Metro Style Apps, more. Free future releases when you subscribe now!
http://p.sf.net/sfu/learndevnow-d2d
_______________________________________________
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users

Reply via email to