title: matplotlib animation with toolbar
body: <p>I have one huge array and I'm trying to create an animation effect. My approach is:</p>
  
  <pre><code>def initPlot(self):
      if not hasattr( self, 'axes' ):
          self.axes = self.figure.add_subplot( 111 )
  
      self.axes.set_title('Monitor data', size=12)
  
      pylab.setp(self.axes.get_xticklabels(), fontsize=8)
      pylab.setp(self.axes.get_yticklabels(), fontsize=8)
      self.maxy = 0
      self.miny = 0
      for i, pt_list in enumerate( self.point_lists ):             
          plot_pts = num.array( pt_list )
          clr = self.clr_list[i]
          self.plot_data = self.axes.plot( plot_pts, linewidth= 1.0, color=clr, )[0]
          self.plot_data.set_xdata(num.arange(len(plot_pts)))
          self.plot_data.set_ydata(plot_pts)
          maxPlot = plot_pts.max()
          minPlot = plot_pts.min()
          if maxPlot &gt; self.maxy:
              self.maxy = maxPlot
          if minPlot &lt; self.miny:
              self.miny = minPlot
  
  
  def draw( self ):
      """Draw data."""                 
      self.axes.set_xbound(lower=self.startPosition, upper=self.startPosition + 1000)
      self.axes.set_ybound(lower=self.miny - 50, upper = self.maxy + 50)        
      self.canvas.draw()
  
  
  def onTimerPassed(self, event):
      if self.animation:
          self.startPosition = self.startPosition + 10
          self.draw()
  </code></pre>
  
  <p>Now this works fine and the animation is what I expect. However I also need to integrate an NavigationToolbar2WxAgg. Here comes my problem. When the animation is active, any zoom/ reposition etc. is automatically canceled from what I can tell by the self.canvas.draw(). So my question is how can I do the plot update that keeps the settings done by the toolbar?</p>
  
  <p>regards,
  Bogdan</p>