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
(16)
2
(22)
3
(28)
4
(17)
5
(17)
6
(7)
7
8
(15)
9
(28)
10
(26)
11
(28)
12
(19)
13
(5)
14
(3)
15
(21)
16
(28)
17
(11)
18
(18)
19
(6)
20
(5)
21
(18)
22
(11)
23
(22)
24
(28)
25
(17)
26
(17)
27
(7)
28
(16)
29
(24)
30
(25)
31
(14)



Showing 20 results of 20

From: Gökhan S. <gok...@gm...> - 2010年03月15日 23:59:09
On Mon, Mar 15, 2010 at 6:18 PM, David <ld...@gm...> wrote:
> Hello everyone,
>
> I hope you can help me with two problems I am struggling with. The second
> question, I imagine, should be rather easy, but I wasn't able to figure it
> out by googling.
>
> a) My graph will have Chinese labels, however mpl does not render the
> Chinese characters. I was unable to find how to teach it some CJK. Could you
> please indicate what the approach to be followed is?
>
Probably you need a unicode font-set that contain all the characters for
those alphabets. You can look at this example to see a simple unicode
demonstration example.
http://matplotlib.sourceforge.net/examples/pylab_examples/unicode_demo.html
Make sure you are using the right font in your matplotlib.
>
> Also, the xlabel is not shown when sizing/saving the graph at (3.6, 2.22)
> inches. Why is that? And how can I make mpl show the xlabel?
>
You have to adjust your label to get it seen. You may try with:
xlab = plt.xlabel("my x-axes label")
xlab.set_position((0.2, 0.1))
>
> b) In the file dea.png (attached) you can see that data points are rendered
> by points ('ko'). Each of these points has an associated name; for example,
> point (1,4) is 'A'. This name, 'A', should be incorporated into the graph so
> as to identify the point. 'A' should be placed right next to the dot. Could
> you please let me know what the easiest way is to solve this problem?
>
Two ways I can think of are: annotate and text functions of pyplot api.
http://matplotlib.sourceforge.net/api/pyplot_api.html
Let me know if these work fine for you.
>
> Thank you very much for your help!
>
> David
>
>
> ------------------------------------------------------------------------------
> Download Intel&#174; Parallel Studio Eval
> Try the new software tools for yourself. Speed compiling, find bugs
> proactively, and fine-tune applications for parallel performance.
> See why Intel Parallel Studio got high marks during beta.
> http://p.sf.net/sfu/intel-sw-dev
> _______________________________________________
> Matplotlib-users mailing list
> Mat...@li...
> https://lists.sourceforge.net/lists/listinfo/matplotlib-users
>
>
-- 
Gökhan
From: Alexander D. <ale...@go...> - 2010年03月15日 23:39:02
Hi,
I would like to create 3D plots. A search revealed the following page:
http://www.scipy.org/Cookbook/Matplotlib/mplot3D
which explains to install matplotlib version 0.99 to use the 3D code.
Unfortunately, after installingmatplotlib-0.99.1.1 (from
matplotlib-0.99.1.2.tar.gz) I am not able to use the 3D code. The
command that show that the correct version is used together with the
error is shown below.
Any idea how I can use this code? Do I have to downgrade to the 0.91.x
maintenance branch? Or do you suggest to use mayavi
(http://code.enthought.com/projects/mayavi/docs/development/html/mayavi/mlab.html)?
I also tried to install the latter, after 1 hour of installing code
and requirements and cmake and easyinstall.. I got the error that VTK
is not installed. So: Any idea how to create a simple 3D scatter plot,
seen from any arbitrary angle?
Thanks
 Alex
In [1]: import matplotlib
In [2]: matplotlib.__version__
Out[2]: '0.99.1.1'
In [3]: import matplotlib.axes3d as p3
---------------------------------------------------------------------------
NotImplementedError Traceback (most recent call last)
/home/alex/Documents/Job/Travel/2010-03_LSC_Pasadena/3D/<ipython
console> in <module>()
/usr/lib/python2.6/site-packages/matplotlib/axes3d.py in <module>()
----> 1 raise NotImplementedError('axes3d is not supported in
matplotlib-0.98. You may want to try the 0.91.x maintenance branch')
NotImplementedError: axes3d is not supported in matplotlib-0.98. You
may want to try the 0.91.x maintenance branch
From: David <ld...@gm...> - 2010年03月15日 23:18:47
Attachments: dea.py dea.png
Hello everyone,
I hope you can help me with two problems I am struggling with. The 
second question, I imagine, should be rather easy, but I wasn't able to 
figure it out by googling.
a) My graph will have Chinese labels, however mpl does not render the 
Chinese characters. I was unable to find how to teach it some CJK. Could 
you please indicate what the approach to be followed is?
Also, the xlabel is not shown when sizing/saving the graph at (3.6, 
2.22) inches. Why is that? And how can I make mpl show the xlabel?
b) In the file dea.png (attached) you can see that data points are 
rendered by points ('ko'). Each of these points has an associated name; 
for example, point (1,4) is 'A'. This name, 'A', should be incorporated 
into the graph so as to identify the point. 'A' should be placed right 
next to the dot. Could you please let me know what the easiest way is to 
solve this problem?
Thank you very much for your help!
David
From: Samuel T. S. <arc...@gm...> - 2010年03月15日 23:14:10
Hi all...
On this afternoon I installed on my ubuntu 8.04 server the python-matplotlib
package and his dependencies.
but If I pay attention right that package installed matplotlib 0.91
on my local desktop wich run windows, I installed the last version...
Anyone knows how do I de-install only matplotlib pack, let only the
dependancies
and install the most recent version?
thanks in advanced...
Samuel
From: <tom...@gm...> - 2010年03月15日 20:43:30
Thanks! :D 
Thank you very much. The ipython -pylab is working great! 
Tomislav
P.S.
Enjoy the Hawaiian sunshine... :D I'm freezing in Munich, Germany...
----- Original Message -----
From: Eric Firing
Sent: 03/15/10 07:59 PM
To: tom...@gm...
Subject: Re: [Matplotlib-users] figure: underlying C/C++ object has been deleted
tom...@gm... wrote:
[...]
> 
> Here is the code with the error:
> 
> 
> http://pastebin.com/3QUws70n
> 
> 
> 
> I don't understand, why would a figure object get deleted after it's 
> shown on the screen? What am I doing wrong?
This is a common "gotcha": don't use pyplot.show() anywhere other than 
at the end of a script, and then only when you want the script to 
display a figure and block. For working interactively with ipython 
(which it appears you are doing, and which is recommended), use "ipython 
-pylab". Then, the figure will be redrawn automatically after pyplot 
functions are called. If you use a more OO approach, say using the 
Axes.plot(...) method rather than the pyplot.plot(...) function, you can 
use pyplot.draw() to force an update when you want one.
Eric
> 
> 
> Thanks in advance,
> 
> Tomislav
From: Eric F. <ef...@ha...> - 2010年03月15日 19:43:26
John Didion wrote:
> The documentation for hist says that the color kwarg can take a sequence
> of rgba tuples. However, anytime I pass a sequence I get:
That is an error in the docstring; it can take only a single color, 
which will be applied to both the edge and the fill.
Eric
> 
> 
> Traceback (most recent call last):
> File "./chromoplot.py", line 283, in <module>
> main() File "./chromoplot.py", line 280, in main
> plot(data_file, figure_file, options)
> File "./chromoplot.py", line 225, in plot
> c.plot(figure_file)
> File "./chromoplot.py", line 220, in plot
> fig.savefig(figure_file)
> File "/Library/Python/2.6/site-packages/matplotlib/figure.py", line
> 1032, in savefig
> self.canvas.print_figure(*args, **kwargs)
> File "/Library/Python/2.6/site-packages/matplotlib/backend_bases.py",
> line 1476, in print_figure
> **kwargs)
> File
> "/Library/Python/2.6/site-packages/matplotlib/backends/backend_agg.py",
> line 358, in print_png
> FigureCanvasAgg.draw(self)
> File
> "/Library/Python/2.6/site-packages/matplotlib/backends/backend_agg.py",
> line 314, in draw
> self.figure.draw(self.renderer)
> File "/Library/Python/2.6/site-packages/matplotlib/artist.py", line 46,
> in draw_wrapper
> draw(artist, renderer, *kl)
> File "/Library/Python/2.6/site-packages/matplotlib/figure.py", line
> 773, in draw
> for a in self.axes: a.draw(renderer)
> File "/Library/Python/2.6/site-packages/matplotlib/artist.py", line 46,
> in draw_wrapper
> draw(artist, renderer, *kl)
> File "/Library/Python/2.6/site-packages/matplotlib/axes.py", line 1735,
> in draw
> a.draw(renderer)
> File "/Library/Python/2.6/site-packages/matplotlib/artist.py", line 46,
> in draw_wrapper
> draw(artist, renderer, *kl)
> File "/Library/Python/2.6/site-packages/matplotlib/patches.py", line
> 298, in draw
> gc.set_foreground(self._edgecolor)
> File "/Library/Python/2.6/site-packages/matplotlib/backend_bases.py",
> line 628, in set_foreground
> self._rgb = colors.colorConverter.to_rgba(fg)
> File "/Library/Python/2.6/site-packages/matplotlib/colors.py", line
> 353, in to_rgba
> raise ValueError('to_rgba: Invalid rgba arg "%s"\n%s' % (str(arg), exc))
> ValueError: to_rgba: Invalid rgba arg "((1, 0, 0, 1), (0, 1, 0, 1))"
> need more than 2 values to unpack 
> 
> 
> ------------------------------------------------------------------------------
> Download Intel&#174; Parallel Studio Eval
> Try the new software tools for yourself. Speed compiling, find bugs
> proactively, and fine-tune applications for parallel performance.
> See why Intel Parallel Studio got high marks during beta.
> http://p.sf.net/sfu/intel-sw-dev
> 
> 
> ------------------------------------------------------------------------
> 
> _______________________________________________
> Matplotlib-users mailing list
> Mat...@li...
> https://lists.sourceforge.net/lists/listinfo/matplotlib-users
From: John D. <jd...@em...> - 2010年03月15日 19:08:14
Attachments: jdidion.vcf
The documentation for hist says that the color kwarg can take a sequence
of rgba tuples. However, anytime I pass a sequence I get:
Traceback (most recent call last):
 File "./chromoplot.py", line 283, in <module>
 main() File "./chromoplot.py", line 280, in main
 plot(data_file, figure_file, options)
 File "./chromoplot.py", line 225, in plot
 c.plot(figure_file)
 File "./chromoplot.py", line 220, in plot
 fig.savefig(figure_file)
 File "/Library/Python/2.6/site-packages/matplotlib/figure.py", line
1032, in savefig
 self.canvas.print_figure(*args, **kwargs)
 File "/Library/Python/2.6/site-packages/matplotlib/backend_bases.py",
line 1476, in print_figure
 **kwargs)
 File
"/Library/Python/2.6/site-packages/matplotlib/backends/backend_agg.py",
line 358, in print_png
 FigureCanvasAgg.draw(self)
 File
"/Library/Python/2.6/site-packages/matplotlib/backends/backend_agg.py",
line 314, in draw
 self.figure.draw(self.renderer)
 File "/Library/Python/2.6/site-packages/matplotlib/artist.py", line 46,
in draw_wrapper
 draw(artist, renderer, *kl)
 File "/Library/Python/2.6/site-packages/matplotlib/figure.py", line
773, in draw
 for a in self.axes: a.draw(renderer)
 File "/Library/Python/2.6/site-packages/matplotlib/artist.py", line 46,
in draw_wrapper
 draw(artist, renderer, *kl)
 File "/Library/Python/2.6/site-packages/matplotlib/axes.py", line 1735,
in draw
 a.draw(renderer)
 File "/Library/Python/2.6/site-packages/matplotlib/artist.py", line 46,
in draw_wrapper
 draw(artist, renderer, *kl)
 File "/Library/Python/2.6/site-packages/matplotlib/patches.py", line
298, in draw
 gc.set_foreground(self._edgecolor)
 File "/Library/Python/2.6/site-packages/matplotlib/backend_bases.py",
line 628, in set_foreground
 self._rgb = colors.colorConverter.to_rgba(fg)
 File "/Library/Python/2.6/site-packages/matplotlib/colors.py", line
353, in to_rgba
 raise ValueError('to_rgba: Invalid rgba arg "%s"\n%s' % (str(arg), exc))
ValueError: to_rgba: Invalid rgba arg "((1, 0, 0, 1), (0, 1, 0, 1))"
need more than 2 values to unpack 
-- 
John Didion
Computational Biology, PhD Student
Fernando Pardo-Manuel de Villena Lab
UNC Chapel Hill
From: Eric F. <ef...@ha...> - 2010年03月15日 18:59:13
tom...@gm... wrote:
[...]
> 
> Here is the code with the error:
> 
> 
> http://pastebin.com/3QUws70n
> 
> 
> 
> I don't understand, why would a figure object get deleted after it's 
> shown on the screen? What am I doing wrong?
This is a common "gotcha": don't use pyplot.show() anywhere other than 
at the end of a script, and then only when you want the script to 
display a figure and block. For working interactively with ipython 
(which it appears you are doing, and which is recommended), use "ipython 
-pylab". Then, the figure will be redrawn automatically after pyplot 
functions are called. If you use a more OO approach, say using the 
Axes.plot(...) method rather than the pyplot.plot(...) function, you can 
use pyplot.draw() to force an update when you want one.
Eric
> 
> 
> Thanks in advance,
> 
> Tomislav
From: Eric F. <ef...@ha...> - 2010年03月15日 18:44:26
Ian Thomas wrote:
> Chris Barker wrote:
>> I think it would be great to have in MPL.
>>
>> What code are you using for the triangulation? Does it do constrained
>> delauney?
> 
> My code only does the contouring; you have to input the triangulation.
> In the examples included with the code I used matplotlib.delaunay to
> do the triangulations so as not to reinvent the wheel.
> 
> To include it in MPL, I would need to improve it somewhat (there are a
> couple of known bugs and insufficient documentation) and there would
> need to be a discussion of the API. At the moment I am using
> 
> tricontour(x, y, triangulation_indices, z, optional_mask)
> 
> followed by the usual contour args (N or V) and kwargs. Is this OK?
> I've also written utility plotting functions triplot, trifill and
> tripcolor; are these wanted?
> 
> In terms of implementation, at the python level I have a TriContourSet
> class which is the same as the existing ContourSet apart from a few
> lines that deal with input arguments and calling the appropriate
> underlying C++ code. Ideally it would be sensible to refactor the
> common python code into a new class (BaseContourSet?) and have
> relatively thin derived ContourSet and TriContourSet classes. But I'm
> not sure you'd like a relatively new mpl contributor to change such
> important code...
Ian,
As the person who fixed major bugs in cntr.c, you have wizard status, so 
go ahead! I have no objection to some refactoring, so long as 
everything works in the end, and is no more difficult to read and 
maintain than what is there now--which I am sure could be improved even 
without the Tri additions.
What sort of timeline do you have in mind?
One possibility would be to develop the tri* functionality at least 
initially as a module in lib/mpl_toolkits, like axes_grid and mplot3d; 
or in a module in lib/matplotlib. This could still take advantage of 
refactoring in contour.py. An advantage is that it would consolidate 
the triangle functionality so it would be easier to find, track, and 
document.
I copied this reply to the devel list--let's continue there as needed.
Eric
> 
> Ian
From: <tom...@gm...> - 2010年03月15日 18:27:58
Hi, 
I forgot to write something in my last email: I just wish to thank the developers of this insanely
great tool. Long live open source. Thank you very much for this, it's the best data/graph manipulation 
software ever.
Now, for my question: I'm not sure if I misunderstood something, or is it a bug of some sort. 
Here is the code with the error:
http://pastebin.com/3QUws70n
I don't understand, why would a figure object get deleted after it's shown on the screen? What am I doing wrong?
Thanks in advance,
Tomislav
From: <tom...@gm...> - 2010年03月15日 17:17:02
Thanks a lot! This worked like a charm. I'll need to dig into matplotlib a lot later, 
but now I have truckloads of bugs in my code to deal with, this will speed me up
significantly.
Thank you again,
Tomislav
----- Original Message -----
From: PH...@Ge...
Sent: 03/15/10 05:40 PM
To: tom...@gm..., mat...@li...
Subject: RE: [Matplotlib-users] axis aspect ratio
Give this a shot:
import matplotlib.pyplot as plt
fig = pl.figure(figsize=(4,4))
ax = fig.add_sublot(1,1,1) # tweak as needed
# [plot your data]
ax.set_aspect(‘equal’)
http://matplotlib.sourceforge.net/api/axes_api.html?highlight=set_aspect#matplotlib.axes.Axes.set_aspect http://matplotlib.sourceforge.net/api/axes_api.html?highlight=set_aspect#matplotlib.axes.Axes.set_aspect 
From:tom...@gm... [mailto:tom...@gm...] 
Sent: Monday, March 15, 2010 9:33 AM
To:mat...@li...
Subject: [Matplotlib-users] axis aspect ratio
Hello everyone, 
I'm using matplotlib for plotting data results from numerical simulations that involve a lot of geometric calculations. 
I did read the tutorial, but I haven't been able to figure out the proper way to set the axis aspect ratio to "1" when 
numerical data is plotted. 
Here is an example of my plot:
http://img715.imageshack.us/img715/9318/projections.png http://img715.imageshack.us/img715/9318/projections.png 
since I need the aspect ratio to be "1" so that I can visually inspect my numerical code for bugs, I would really
appreciate the help. 
I've loaded the data using pylab.load and I've plotted the files without using figure or axes, just plain old
pyplot.
From: <PH...@Ge...> - 2010年03月15日 16:41:07
Give this a shot:
import matplotlib.pyplot as plt
fig = pl.figure(figsize=(4,4))
ax = fig.add_sublot(1,1,1) # tweak as needed
# [plot your data]
ax.set_aspect(‘equal’)
http://matplotlib.sourceforge.net/api/axes_api.html?highlight=set_aspect#matplotlib.axes.Axes.set_aspect
From: tom...@gm... [mailto:tom...@gm...]
Sent: Monday, March 15, 2010 9:33 AM
To: mat...@li...
Subject: [Matplotlib-users] axis aspect ratio
Hello everyone,
I'm using matplotlib for plotting data results from numerical simulations that involve a lot of geometric calculations.
I did read the tutorial, but I haven't been able to figure out the proper way to set the axis aspect ratio to "1" when
numerical data is plotted.
Here is an example of my plot:
http://img715.imageshack.us/img715/9318/projections.png
since I need the aspect ratio to be "1" so that I can visually inspect my numerical code for bugs, I would really
appreciate the help.
I've loaded the data using pylab.load and I've plotted the files without using figure or axes, just plain old
pyplot.
From: <tom...@gm...> - 2010年03月15日 16:33:55
Hello everyone, 
I'm using matplotlib for plotting data results from numerical simulations that involve a lot of geometric calculations. 
I did read the tutorial, but I haven't been able to figure out the proper way to set the axis aspect ratio to "1" when 
numerical data is plotted. 
Here is an example of my plot:
http://img715.imageshack.us/img715/9318/projections.png
since I need the aspect ratio to be "1" so that I can visually inspect my numerical code for bugs, I would really
appreciate the help. 
I've loaded the data using pylab.load and I've plotted the files without using figure or axes, just plain old
pyplot.
On 15/03/2010 14:37, Kim Hansen wrote:
> Hi Werner
>
> 2010年3月15日 Werner F. Bruhin <wer...@fr... 
> <mailto:wer...@fr...>>
>
> Hi Kim,
>
>
> Changing the line 560 in mathtext.py from:
> font = FT2Font(basename)
> to:
> font = FT2Font(str(basename))
>
> Fixed it for me, I don't know what FT2Font does and why this
> matters - hopefully someone else can expand on this.
>
> This worked here as well - sort of, at least.
It was just a guess, as I noticed that the other call to FT2Font is 
using str too.
> It does not crash anymore, but the LaTeX $\alpha-\beta$ in the title 
> is not rendered correctly in the title of the graph for the users who 
> had problems before.
Yeap, I see this now too.
> I guess it must be due to some fonts not being available in the dist, 
> which are available to me and others. I do not know if there is a way 
> to patch up setup.py such that the needed fonts are included in the dist?
It should be there, i.e. mpl-data in the lib/site-packages/matplotlib 
folder has the same number of files and folders as the one created by 
setup.py in dist.
But it obviously doesn't find it or some other setting to handle the 
LaTex stuff is not there.
Put this at the top of alphabeta.py, i.e. just after import matplotlib
matplotlib.verbose.level = u'debug'
and change setup.py to generate a console app. If I run this on my dev 
machine the output shows that fonts are found, but if I run it on the 
py2exe'd version lots of STIX fonts are not found. Even so these fonts 
are in mpl-data/fonts/ttf of the py2exe dist folder.
So, I think/guess that the font searching is not done correctly, as 
running with verbose "debug" it shows that it finds the mpl-data folder 
in the dist folder or wherever you copy dist too.
Hopefully someone who knows how the font searching is done can help 
out/point to the culprit.
>
> Attached your setup.py a bit simplified as you are using
> matplotlib 0.99.
>
> Thank you. I am using your setup.py now. It was very kind of you to 
> send that.
You are welcome
Werner
From: Nathan H. <iwa...@go...> - 2010年03月15日 13:36:02
Thanks, just what I was looking for.
Nathan
On 15 March 2010 12:55, Andre Walker-Loud <wal...@gm...> wrote:
> Hi Nathan,
>
> It sounds like this example is what you want
>
> http://matplotlib.sourceforge.net/examples/pylab_examples/axes_demo.html
>
>
> Cheers,
> Andre
>
>
>
>
> On Mar 15, 2010, at 7:44 AM, Nathan Harmston wrote:
>
>> Hi everyone,
>>
>> I've been trying (with no luck) to add a plot inside a plot, like this
>> (apologies for the ascii art), the smaller box represents the plot I
>> want to add. The thing I know it doesnt want to be a subplot and I
>> can't find an example of this plot in the gallery. It is possible in R
>> with some hacking....and I'm hoping its possible in matplotlib.
>>
>> |    _________
>> |    |        |
>> |    |        |
>> |    |________|
>> |
>> |
>> |
>> |
>> --------------------------------------------------
>>
>> Any ideas on how to do this? I m guessing/hoping someone must have
>> done it before?
>>
>> Many thanks in advance
>>
>> Nathan
>>
>>
>> ------------------------------------------------------------------------------
>> Download Intel&#174; Parallel Studio Eval
>> Try the new software tools for yourself. Speed compiling, find bugs
>> proactively, and fine-tune applications for parallel performance.
>> See why Intel Parallel Studio got high marks during beta.
>> http://p.sf.net/sfu/intel-sw-dev
>> _______________________________________________
>> Matplotlib-users mailing list
>> Mat...@li...
>> https://lists.sourceforge.net/lists/listinfo/matplotlib-users
>
>
From: Andre Walker-L. <wal...@gm...> - 2010年03月15日 12:56:02
Hi Nathan,
It sounds like this example is what you want
http://matplotlib.sourceforge.net/examples/pylab_examples/axes_demo.html
Cheers,
Andre
On Mar 15, 2010, at 7:44 AM, Nathan Harmston wrote:
> Hi everyone,
>
> I've been trying (with no luck) to add a plot inside a plot, like this
> (apologies for the ascii art), the smaller box represents the plot I
> want to add. The thing I know it doesnt want to be a subplot and I
> can't find an example of this plot in the gallery. It is possible in R
> with some hacking....and I'm hoping its possible in matplotlib.
>
> | _________
> | | |
> | | |
> | |________|
> |
> |
> |
> |
> --------------------------------------------------
>
> Any ideas on how to do this? I m guessing/hoping someone must have
> done it before?
>
> Many thanks in advance
>
> Nathan
>
> ------------------------------------------------------------------------------
> Download Intel&#174; Parallel Studio Eval
> Try the new software tools for yourself. Speed compiling, find bugs
> proactively, and fine-tune applications for parallel performance.
> See why Intel Parallel Studio got high marks during beta.
> http://p.sf.net/sfu/intel-sw-dev
> _______________________________________________
> Matplotlib-users mailing list
> Mat...@li...
> https://lists.sourceforge.net/lists/listinfo/matplotlib-users
From: Pierre de B. <pd...@ul...> - 2010年03月15日 12:56:01
Hello,
This is usually done by using several calls to "axes", specifying the 
coordinates of the different plots in the figure.
The "plot" coordinates are in the range 0..1 times 0..1.
An example is provided here
http://matplotlib.sourceforge.net/examples/pylab_examples/axes_demo.html
with two plots in the main one, you can skip one of them.
Pierre
Le 15 mars 10 à 12:44, Nathan Harmston a écrit :
> Hi everyone,
>
> I've been trying (with no luck) to add a plot inside a plot, like this
> (apologies for the ascii art), the smaller box represents the plot I
> want to add. The thing I know it doesnt want to be a subplot and I
> can't find an example of this plot in the gallery. It is possible in R
> with some hacking....and I'm hoping its possible in matplotlib.
>
> | _________
> | | |
> | | |
> | |________|
> |
> |
> |
> |
> --------------------------------------------------
>
> Any ideas on how to do this? I m guessing/hoping someone must have
> done it before?
>
> Many thanks in advance
>
> Nathan
>
> ---------------------------------------------------------------------- 
> --------
> Download Intel&#174; Parallel Studio Eval
> Try the new software tools for yourself. Speed compiling, find bugs
> proactively, and fine-tune applications for parallel performance.
> See why Intel Parallel Studio got high marks during beta.
> http://p.sf.net/sfu/intel-sw-dev
> _______________________________________________
> Matplotlib-users mailing list
> Mat...@li...
> https://lists.sourceforge.net/lists/listinfo/matplotlib-users
From: Werner F. B. <wer...@fr...> - 2010年03月15日 12:50:58
Attachments: setup.py
Hi Kim,
On 15/03/2010 10:57, Kim Hansen wrote:
> Hi group,
> I have previously had success with py2exe and matplotlib, using a
> specialized setup.py like the attached one (which is adapted from
> http://www.py2exe.org/index.cgi/MatPlotLib).
> However, now I have tried to go a step further and integrate some
> Tkinter controls in the GUI for a prototype, see attached alphabeta.py
> If I do a python setup.exe py2exe with this setup file on the attached
> Tkinter/matplotlib and alphabeta.exe is successfully created.
> However, it does not run for everyone else:
> Myself: Works like a charm
> A user with a python environment who make py2exes himself: Crashes on
> startup with the attached error log
> A user with just a Python environment: Works!
> A user with no Python environment: Crashes on startup with the same log.
> The log does not give me any good ideas as to how I could modify
> setup.py to get it working.
> Any good ideas?
Changing the line 560 in mathtext.py from:
 font = FT2Font(basename)
to:
 font = FT2Font(str(basename))
Fixed it for me, I don't know what FT2Font does and why this matters - 
hopefully someone else can expand on this.
Attached your setup.py a bit simplified as you are using matplotlib 0.99.
Werner
From: Nathan H. <iwa...@go...> - 2010年03月15日 12:15:30
Hi everyone,
I've been trying (with no luck) to add a plot inside a plot, like this
(apologies for the ascii art), the smaller box represents the plot I
want to add. The thing I know it doesnt want to be a subplot and I
can't find an example of this plot in the gallery. It is possible in R
with some hacking....and I'm hoping its possible in matplotlib.
| _________
| | |
| | |
| |________|
|
|
|
|
--------------------------------------------------
Any ideas on how to do this? I m guessing/hoping someone must have
done it before?
Many thanks in advance
Nathan
From: Ian T. <ian...@go...> - 2010年03月15日 10:47:02
Chris Barker wrote:
> hmm -- I wonder if a post to matplotlib-devel is in order. Most of those
> folks are on this list, to, but may not be following this thread.
I'll post to matplotlib-devel shortly and see what response I get.
> By the way, it sounds like your contouring code is in C++ -- is that
> important?
Yes, it is C++ and it is important - that's what I've got and hence
that's what I'm offering! Portability should be fine as I'm only
using some of the basic STL containers which are already used by, for
example, the matplotlib delaunay code.
Ian
1 message has been excluded from this view by a project administrator.

Showing 20 results of 20

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 によって変換されたページ (->オリジナル) /