SourceForge logo
SourceForge logo
Menu

matplotlib-users — Discussion related to using matplotlib

You can subscribe to this list here.

2003 Jan
Feb
Mar
Apr
May
(3)
Jun
Jul
Aug
(12)
Sep
(12)
Oct
(56)
Nov
(65)
Dec
(37)
2004 Jan
(59)
Feb
(78)
Mar
(153)
Apr
(205)
May
(184)
Jun
(123)
Jul
(171)
Aug
(156)
Sep
(190)
Oct
(120)
Nov
(154)
Dec
(223)
2005 Jan
(184)
Feb
(267)
Mar
(214)
Apr
(286)
May
(320)
Jun
(299)
Jul
(348)
Aug
(283)
Sep
(355)
Oct
(293)
Nov
(232)
Dec
(203)
2006 Jan
(352)
Feb
(358)
Mar
(403)
Apr
(313)
May
(165)
Jun
(281)
Jul
(316)
Aug
(228)
Sep
(279)
Oct
(243)
Nov
(315)
Dec
(345)
2007 Jan
(260)
Feb
(323)
Mar
(340)
Apr
(319)
May
(290)
Jun
(296)
Jul
(221)
Aug
(292)
Sep
(242)
Oct
(248)
Nov
(242)
Dec
(332)
2008 Jan
(312)
Feb
(359)
Mar
(454)
Apr
(287)
May
(340)
Jun
(450)
Jul
(403)
Aug
(324)
Sep
(349)
Oct
(385)
Nov
(363)
Dec
(437)
2009 Jan
(500)
Feb
(301)
Mar
(409)
Apr
(486)
May
(545)
Jun
(391)
Jul
(518)
Aug
(497)
Sep
(492)
Oct
(429)
Nov
(357)
Dec
(310)
2010 Jan
(371)
Feb
(657)
Mar
(519)
Apr
(432)
May
(312)
Jun
(416)
Jul
(477)
Aug
(386)
Sep
(419)
Oct
(435)
Nov
(320)
Dec
(202)
2011 Jan
(321)
Feb
(413)
Mar
(299)
Apr
(215)
May
(284)
Jun
(203)
Jul
(207)
Aug
(314)
Sep
(321)
Oct
(259)
Nov
(347)
Dec
(209)
2012 Jan
(322)
Feb
(414)
Mar
(377)
Apr
(179)
May
(173)
Jun
(234)
Jul
(295)
Aug
(239)
Sep
(276)
Oct
(355)
Nov
(144)
Dec
(108)
2013 Jan
(170)
Feb
(89)
Mar
(204)
Apr
(133)
May
(142)
Jun
(89)
Jul
(160)
Aug
(180)
Sep
(69)
Oct
(136)
Nov
(83)
Dec
(32)
2014 Jan
(71)
Feb
(90)
Mar
(161)
Apr
(117)
May
(78)
Jun
(94)
Jul
(60)
Aug
(83)
Sep
(102)
Oct
(132)
Nov
(154)
Dec
(96)
2015 Jan
(45)
Feb
(138)
Mar
(176)
Apr
(132)
May
(119)
Jun
(124)
Jul
(77)
Aug
(31)
Sep
(34)
Oct
(22)
Nov
(23)
Dec
(9)
2016 Jan
(26)
Feb
(17)
Mar
(10)
Apr
(8)
May
(4)
Jun
(8)
Jul
(6)
Aug
(5)
Sep
(9)
Oct
(4)
Nov
Dec
2017 Jan
(5)
Feb
(7)
Mar
(1)
Apr
(5)
May
Jun
(3)
Jul
(6)
Aug
(1)
Sep
Oct
(2)
Nov
(1)
Dec
2018 Jan
Feb
Mar
Apr
(1)
May
Jun
Jul
Aug
Sep
Oct
Nov
Dec
2020 Jan
Feb
Mar
Apr
May
(1)
Jun
Jul
Aug
Sep
Oct
Nov
Dec
2025 Jan
(1)
Feb
Mar
Apr
May
Jun
Jul
Aug
Sep
Oct
Nov
Dec
S M T W T F S




1
(19)
2
(28)
3
(8)
4
(15)
5
(20)
6
(23)
7
(12)
8
(11)
9
(13)
10
(4)
11
(9)
12
(34)
13
(33)
14
(24)
15
(15)
16
(12)
17
(8)
18
(5)
19
(5)
20
(6)
21
(10)
22
(9)
23
(18)
24
(10)
25
(7)
26
(13)
27
(18)
28
(29)
29
(4)
30
(5)
31
(2)

Showing 10 results of 10

From: Mike A. <mba...@wi...> - 2009年10月21日 21:50:20
Hi,
I have a piece of code that creates a plot without warning when using 
just fill(), but gives a warning when using fill_between() because 
that function doesn't seem to actually do register values passed to it 
by the "label" parameter.
The warning happens when I try to make a legend after using 
fill_between():
 /cms/sw/python/2.5/lib/python2.5/site-packages/ 
matplotlib-0.99.1.1_r0-py2.5-linux-x86_64.egg/matplotlib/axes.py:4014: 
UserWarning: No labeled objects found. Use label='...' kwarg on 
individual plots.
 warnings.warn("No labeled objects found. "
In essence this code works fine when I use fill() rather than 
fill_between():
--------------------
for column in sorted(yValues):
	ax.fill_between(xValues, yValues[column], label=column)
legend = plt.legend(bbox_to_anchor=(1.3, 1), shadow=True, fancybox=True)
--------------------
That is, the legend finds the labels when I use fill(), but not when I 
use fill_between().
Why is that?
Mike
From: Jae-Joon L. <lee...@gm...> - 2009年10月21日 17:07:49
The api related to ticks and ticklabels is a bit confusing, at least
for me. So, often, it seems best to directly change the tick
properties.
for t in axcbar.xaxis.get_major_ticks():
 t.tick1On = True
 t.tick2On = True
 t.label1On = False
 t.label2On = True
-JJ
On Wed, Oct 21, 2009 at 11:24 AM, Thomas Robitaille
<tho...@gm...> wrote:
> Hi,
>
> I'm trying to plot a horizontal colorbar with labels on top. I can use
>
> axcbar = fig.add_axes([0.2, 0.85, 0.6, 0.03])
> axcbar.xaxis.set_ticks_position('top')
> cbar = fig.colorbar(s, cax=axcbar, orientation='horizontal')
>
> but then I lose the ticks on the bottom of the colorbar. However,
> setting
>
> axcbar.xaxis.set_ticks_position('both')
>
> causes the labels to be on the bottom. Is there a way to have labels
> on the top while keeping ticks on both the top and bottom?
>
> Thanks,
>
> Thomas
>
>
> ------------------------------------------------------------------------------
> Come build with us! The BlackBerry(R) Developer Conference in SF, CA
> is the only developer event you need to attend this year. Jumpstart your
> developing skills, take BlackBerry mobile applications to market and stay
> ahead of the curve. Join us from November 9 - 12, 2009. Register now!
> http://p.sf.net/sfu/devconference
> _______________________________________________
> Matplotlib-users mailing list
> Mat...@li...
> https://lists.sourceforge.net/lists/listinfo/matplotlib-users
>
From: Thomas R. <tho...@gm...> - 2009年10月21日 15:25:00
Hi,
I'm trying to plot a horizontal colorbar with labels on top. I can use
axcbar = fig.add_axes([0.2, 0.85, 0.6, 0.03])
axcbar.xaxis.set_ticks_position('top')
cbar = fig.colorbar(s, cax=axcbar, orientation='horizontal')
but then I lose the ticks on the bottom of the colorbar. However, 
setting
axcbar.xaxis.set_ticks_position('both')
causes the labels to be on the bottom. Is there a way to have labels 
on the top while keeping ticks on both the top and bottom?
Thanks,
Thomas
From: Michael D. <md...@st...> - 2009年10月21日 13:29:39
I have fixed this bug that was causing peaks to be truncated in SVN 
r7895 and r7896. It should make it into the next bugfix release.
Mike
Michael Droettboom wrote:
> It looks like the path simplification code is failing on this. As a 
> workaround, you can turn it off:
>
> rcParams['path.simplify'] = False
>
> or reduce the threshold below which vertices are removed:
>
> rcParams['path.simplify_threshold'] = 0.0001
>
> In the meantime, I'll look further into why this is failing. Perhaps we 
> need a lower default threshold.
>
> Mike
>
> Henrik Wallin wrote:
> 
>> Hello all,
>>
>> I'm sorry if this has been treated before, but I haven't found
>> anything when searching the archives or the net.
>>
>> Basically, the problem surfaces when plotting FFT spectras using many
>> data points. The amplitudes of the peaks in the spectra then seem to
>> depend on the size of the plot window.
>>
>> Example code:
>>
>>
>> 
>> 
>>>>> from pylab import *
>>>>> t=arange(65536)
>>>>> plot(abs(fft(sin(2*pi*.01*t)*blackman(len(t)))))
>>>>> 
>>>>> 
>> [<matplotlib.lines.Line2D object at 0x03871990>]
>> 
>> 
>>>>> show()
>>>>> 
>>>>> 
>> With the original window size (WXAgg backend), I get maximum peaks at
>> about 390. Zooming in on the peak will increase the amplitude.
>> Resizing the window can also make the amplitude increase.
>>
>> The expected amplitude is:
>>
>> 
>> 
>>>>> max(abs(fft(sin(2*pi*.01*t)*blackman(len(t)))))
>>>>> 
>>>>> 
>> 12891.96683092583
>>
>> Is this a known problem, or should I file a bug report? Is there any
>> workaround (except decreasing the length of t, and thus the level of
>> detail)?
>>
>> I'm using ActivePython 2.6.3.7 for windows, matplotlib 0.99.1 binary,
>> numpy 1.3.0 and wxPython-unicode-2.8.10.1. I've also tried with the
>> TkAgg backend, which gives similar results.
>>
>> Thanks,
>> Henrik
>>
>> ------------------------------------------------------------------------------
>> Come build with us! The BlackBerry(R) Developer Conference in SF, CA
>> is the only developer event you need to attend this year. Jumpstart your
>> developing skills, take BlackBerry mobile applications to market and stay 
>> ahead of the curve. Join us from November 9 - 12, 2009. Register now!
>> http://p.sf.net/sfu/devconference
>> _______________________________________________
>> Matplotlib-users mailing list
>> Mat...@li...
>> https://lists.sourceforge.net/lists/listinfo/matplotlib-users
>> 
>> 
>
> 
-- 
Michael Droettboom
Science Software Branch
Operations and Engineering Division
Space Telescope Science Institute
Operated by AURA for NASA
From: Michael D. <md...@st...> - 2009年10月21日 12:45:14
It looks like the path simplification code is failing on this. As a 
workaround, you can turn it off:
 rcParams['path.simplify'] = False
or reduce the threshold below which vertices are removed:
 rcParams['path.simplify_threshold'] = 0.0001
In the meantime, I'll look further into why this is failing. Perhaps we 
need a lower default threshold.
Mike
Henrik Wallin wrote:
> Hello all,
>
> I'm sorry if this has been treated before, but I haven't found
> anything when searching the archives or the net.
>
> Basically, the problem surfaces when plotting FFT spectras using many
> data points. The amplitudes of the peaks in the spectra then seem to
> depend on the size of the plot window.
>
> Example code:
>
>
> 
>>>> from pylab import *
>>>> t=arange(65536)
>>>> plot(abs(fft(sin(2*pi*.01*t)*blackman(len(t)))))
>>>> 
> [<matplotlib.lines.Line2D object at 0x03871990>]
> 
>>>> show()
>>>> 
>
> With the original window size (WXAgg backend), I get maximum peaks at
> about 390. Zooming in on the peak will increase the amplitude.
> Resizing the window can also make the amplitude increase.
>
> The expected amplitude is:
>
> 
>>>> max(abs(fft(sin(2*pi*.01*t)*blackman(len(t)))))
>>>> 
> 12891.96683092583
>
> Is this a known problem, or should I file a bug report? Is there any
> workaround (except decreasing the length of t, and thus the level of
> detail)?
>
> I'm using ActivePython 2.6.3.7 for windows, matplotlib 0.99.1 binary,
> numpy 1.3.0 and wxPython-unicode-2.8.10.1. I've also tried with the
> TkAgg backend, which gives similar results.
>
> Thanks,
> Henrik
>
> ------------------------------------------------------------------------------
> Come build with us! The BlackBerry(R) Developer Conference in SF, CA
> is the only developer event you need to attend this year. Jumpstart your
> developing skills, take BlackBerry mobile applications to market and stay 
> ahead of the curve. Join us from November 9 - 12, 2009. Register now!
> http://p.sf.net/sfu/devconference
> _______________________________________________
> Matplotlib-users mailing list
> Mat...@li...
> https://lists.sourceforge.net/lists/listinfo/matplotlib-users
> 
-- 
Michael Droettboom
Science Software Branch
Operations and Engineering Division
Space Telescope Science Institute
Operated by AURA for NASA
From: Henrik W. <e9h...@gm...> - 2009年10月21日 12:04:19
Hello all,
I'm sorry if this has been treated before, but I haven't found
anything when searching the archives or the net.
Basically, the problem surfaces when plotting FFT spectras using many
data points. The amplitudes of the peaks in the spectra then seem to
depend on the size of the plot window.
Example code:
>>> from pylab import *
>>> t=arange(65536)
>>> plot(abs(fft(sin(2*pi*.01*t)*blackman(len(t)))))
[<matplotlib.lines.Line2D object at 0x03871990>]
>>> show()
With the original window size (WXAgg backend), I get maximum peaks at
about 390. Zooming in on the peak will increase the amplitude.
Resizing the window can also make the amplitude increase.
The expected amplitude is:
>>> max(abs(fft(sin(2*pi*.01*t)*blackman(len(t)))))
12891.96683092583
Is this a known problem, or should I file a bug report? Is there any
workaround (except decreasing the length of t, and thus the level of
detail)?
I'm using ActivePython 2.6.3.7 for windows, matplotlib 0.99.1 binary,
numpy 1.3.0 and wxPython-unicode-2.8.10.1. I've also tried with the
TkAgg backend, which gives similar results.
Thanks,
Henrik
From: Auré G. <aur...@ya...> - 2009年10月21日 11:55:21
Hi Laurent,
I think I might have found a way to solve your problem: instead of creating your axes using pylab.suplot, you should create the axes using the class way. I modified your code below and it works fine without loosing speed in the frame rate. Only thing is, I have no clue as to what is really the underlying problem... my best guess is that there is a conflict between pylab and the general class. I very rearely use pylab directly unless the problem is really simple, because I saw several posts mentioning possible conflicts.
Hope this helps you.
Cheers,
Aurélien
-----
import sys
import pylab as p
import matplotlib as mpl
import numpy as npy
import time
 
fig = p.figure(figsize=(8.,4.))
#ax = p.subplot(212)
ax = fig.add_axes((.05,.55,.9,.4))
#ax2 = p.subplot(211)
ax2 = fig.add_axes((.05,.05,.9,.4))
canvas = ax.figure.canvas
# create the initial line
x = npy.arange(0,2*npy.pi,0.01)
#line, = p.plot(x, npy.sin(x), animated=True, lw=2)
line, = ax.plot(x, npy.sin(x), animated=True, lw=2)
line2, = ax2.plot(x, npy.cos(x), animated=True, lw=2)
def run(*args):
 background = canvas.copy_from_bbox(ax.bbox)
 background2 = canvas.copy_from_bbox(ax2.bbox)
 # for profiling
 tstart = time.time()
 while 1:
 # restore the clean slate background
 canvas.restore_region(background)
 canvas.restore_region(background2)
 # update the data
 line.set_ydata(npy.sin(x+run.cnt/10.0))
 line2.set_ydata(npy.cos(x+run.cnt/10.0))
 # just draw the animated artist
 ax.draw_artist(line)
 ax2.draw_artist(line2)
 # just redraw the axes rectangle
 canvas.blit(ax.bbox)
 canvas.blit(ax2.bbox)
 #canvas.blit(ax.get_figure().bbox) 
 if run.cnt==100:
 # print the timing info and quit
 print 'FPS:' , 100/(time.time()-tstart)
 #return
 sys.exit() 
 run.cnt += 1
run.cnt = 0
#no need for the following since it is done directly when creating the axes
#p.subplots_adjust(left=0.3, bottom=0.3) # check for flipy bugs
#p.grid() # to ensure proper background restore
ax.grid() # to ensure proper background restore
ax2.grid() # to ensure proper background restore
manager = p.get_current_fig_manager()
manager.window.after(100, run)
p.show()
------------------------------
Message: 2
Date: 2009年10月15日 18:40:22 +0200
From: Laurent Dufr?chou <lau...@gm...>
Subject: Re: [Matplotlib-users] [Solved] Little issue with blitting
 technique
To: 'Aur? Gourrier' <aur...@ya...>,
 <mat...@li...>
Message-ID: <4ad...@mx...>
Content-Type: text/plain; charset="iso-8859-1"
Hi Aur?,
Taking this example (FPS is computed at the end of the loop each 100
frames):
(this is the same example as you but not using FileUtils10)
################################################
import sys
import pylab as p
import numpy as npy
import time
ax2 = p.subplot(212)
ax = p.subplot(211)
canvas = ax.figure.canvas
# create the initial line
x = npy.arange(0,2*npy.pi,0.01)
line, = p.plot(x, npy.sin(x), animated=True, lw=2)
def run(*args):
 background = canvas.copy_from_bbox(ax.bbox)
 # for profiling
 tstart = time.time()
 while 1:
 # restore the clean slate background
 canvas.restore_region(background)
 # update the data
 line.set_ydata(npy.sin(x+run.cnt/10.0))
 # just draw the animated artist
 ax.draw_artist(line)
 # just redraw the axes rectangle
 canvas.blit(ax.bbox)
 if run.cnt==100:
 # print the timing info and quit
 print 'FPS:' , 100/(time.time()-tstart)
 return
 run.cnt += 1
run.cnt = 0
p.subplots_adjust(left=0.3, bottom=0.3) # check for flipy bugs
p.grid() # to ensure proper background restore
manager = p.get_current_fig_manager()
manager.window.after(100, run)
p.show()
################################################
This example will work on my machine @99FPS.
Now replace:
ax2 = p.subplot(212)
ax = p.subplot(211)
with:
ax = p.subplot(212)
ax2 = p.subplot(211)
The image is buggy because the blitting is no more working, still I get
86FPS. So let say no change.
Now replace ?ax.bbox? with ?ax.get_figure().bbox?:
The bug disappear and I get a small 20 FPS?
Tested under windows vista , matplotlib 0.99.1, python 2.5.4.
Laurent
Ps: I think ax.getFigure().bbox is getting the whole picture so this is why
it is slower.
De : Aur? Gourrier [mailto:aur...@ya...] 
Envoy? : jeudi 15 octobre 2009 10:32
? : mat...@li...
Objet : Re: [Matplotlib-users] [Solved] Little issue with blitting technique
>On Tue, Oct 13, 2009 at 5:06 PM, Laurent Dufr?chou
><lau...@gm...> wrote:
>> Hey, coparing on how GTK2 example is done I've seen a difference between
the two!
>>
>> In QT4Agg example and WX example the code use:
>>
>> canvas.copy_from_bbox(ax.bbox)
>> replacing all occurrence of ax.bbox with ax.get_figure().bbox solved all
the issue I add.
>>
>
>I'm not sure why using ax.bbox does not work, and it SHOULD work.
>Note that animation_blit_gtk.py DOES use ax.bbox.
>
>> Perhaps we should correct the examples.
>> I can send you the good working example if you want.
>
>If using ax.bbox does not work, than it is a bug (either mpl or the
example).
>Unfortunately, this seems to happen only on windows.
>So, please file a bug report (again).
>
>Regards,
>
>-JJ
>
Hy guys,
Just saw your posts. I don't understand the business with the
ax.get_figure().bbox.
I'm also using windows, and a modified version of the animation_blit_tk.py
using imshow work fine for me.
I just checked whether the get_figure() changes anything and I get exactly
the same result in terms of performance.
I attach the code below if it can be of any use.
Cheers,
Aur?
# For detailed comments on animation and the techniqes used here, see
# the wiki entry http://www.scipy.org/Cookbook/Matplotlib/Animations
import matplotlib
matplotlib.use('TkAgg')
import sys
import pylab as p
import matplotlib.numerix as nx
import time
from FileUtils10 import fileHandling
# for profiling
tstart = time.time()
tprevious = time.time()
fnamelist = ['....']
ax = p.subplot(111)
canvas = ax.figure.canvas
print 't1 ',time.time()-tprevious
tprevious = time.time()
# create the initial line
dataarr = fileHandling(fnamelist[0]).read()
#print dataarr.dtype
#dataarr = dataarr.astype('uint8')
print 't2 ',time.time()-tprevious
tprevious = time.time()
image = p.imshow(dataarr, animated=True)
print 't3 ',time.time()-tprevious
tprevious = time.time()
def run(*args):
 tprevious = time.time()
 background = canvas.copy_from_bbox(ax.bbox)
 print 't4 ',time.time()-tprevious
 tprevious = time.time()
 while 1:
 #print fnamelist[run.cnt]
 # restore the clean slate background
 canvas.restore_region(background)
 print 't5 ',time.time()-tprevious
 tprevious = time.time()
 # update the data
 dataarr = fileHandling(fnamelist[run.cnt]).readMCCD()
 dataarr *= run.cnt
 print 't6 ',time.time()-tprevious
 tprevious = time.time()
 image.set_data(dataarr)
 print 't7 ',time.time()-tprevious
 tprevious = time.time()
 # just draw the animated artist
 ax.draw_artist(image)
 print 't8 ',time.time()-tprevious
 tprevious = time.time()
 # just redraw the axes rectangle
 canvas.blit(ax.bbox)
 print 't9 ',time.time()-tprevious
 tprevious = time.time()
 if fnamelist[run.cnt] == fnamelist[-1]:
 # print the timing info and quit
 print 'total time:' , time.time()-tstart
 print 'FPS:' , 1000./(time.time()-tstart)
 p.close('all')
 sys.exit()
 run.cnt += 1
run.cnt = 0
p.subplots_adjust(left=0.3, bottom=0.3) # check for flipy bugs
p.grid() # to ensure proper background restore
manager = p.get_current_fig_manager()
manager.window.after(100, run)
p.show()
-------------- next part --------------
An HTML attachment was scrubbed...
------------------------------
------------------------------------------------------------------------------
Come build with us! The BlackBerry(R) Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay 
ahead of the curve. Join us from November 9 - 12, 2009. Register now!
http://p.sf.net/sfu/devconference
------------------------------
_______________________________________________
Matplotlib-users mailing list
Mat...@li...
https://lists.sourceforge.net/lists/listinfo/matplotlib-users
End of Matplotlib-users Digest, Vol 41, Issue 51
************************************************
 
From: NIE C. <nie...@gm...> - 2009年10月21日 09:15:03
I mean, it's quite time-consuming to find the function I want on the net
and the pdf version is not so convenient as the chm version. Anybody any
idea?
From: Christian M. <mee...@im...> - 2009年10月21日 09:01:20
Hi,
Does anyone provide a script / patch to create zap symbols (e.g. like
http://home.gna.org/pychart/doc/module-coord.html#module-coord ) to
break an axis?
TIA
Christian
From: Jason K. <jas...@gm...> - 2009年10月21日 01:16:05
I'm new to matplotlib and python GUIs in general, so I apologize if I'm
missing something fundamental in my understanding of the matplotlib canvas -
figure - etc model. That said...
I'm working on a small matplotlib app using PyQT4. It involves selecting an
arbitrary number of data files and breaking each down into a group of 6
contour subplots. I want to be able to switch between contour plots from
each data set quickly to compare and contrast, so my thought was to
front-load the data analysis and figure creation and store them, then update
the displayed figure with a stored figure. I am not able to get the stored
figures to display though.
In attempt to debug/understand what's going on, I have the following:
class InputWindow (QtGui.QWidget):
 def __init__ (self, parent=None):
...
 self.dpi = 100
 self.fig = Figure((9.0, 6.0), dpi=self.dpi)
 self.canvas = FigureCanvas(self.fig)
 self.vbox = QtGui.QVBoxLayout()
 self.vbox.addLayout (grid)
 self.vbox.addLayout (self.hbox_pbs)
 self.vbox.addWidget (self.canvas)
 self.vbox.addStretch (1)
 self.setLayout (self.vbox)
 self.resize (900, 600)
 self.fig.add_subplot(111, aspect='equal')
...
This works fine and creates an empty plot. I can clear this figure with
self.fig.clear() and add subplots to it with self.fig.add_subplot upon
pushing a button in the UI. What I can't do is something like this:
 def Process (self):
 self.fig.clear() 
 fig2 = Figure((9.0, 6.0), dpi=self.dpi)
 fig2.add_subplot(211, aspect='equal')
 self.fig = fig2
 self.canvas.draw()
This will clear the figure, but it doesn't update with the contents of fig2. 
If I look at the properties of self.fig, they match those of fig2 though. 
Any help on what I need to do to get something like self.fig = fig2 working?
Thanks,
J
-- 
View this message in context: http://www.nabble.com/Setting-Figure-%3D-Figure-possible--tp25985129p25985129.html
Sent from the matplotlib - users mailing list archive at Nabble.com.

Showing 10 results of 10

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.
Thanks for helping keep SourceForge clean.
X





Briefly describe the problem (required):
Upload screenshot of ad (required):
Select a file, or drag & drop file here.
Screenshot instructions:

Click URL instructions:
Right-click on the ad, choose "Copy Link", then paste here →
(This may not be possible with some types of ads)

More information about our ad policies

Ad destination/click URL:

AltStyle によって変換されたページ (->オリジナル) /