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

Showing 22 results of 22

From: Mauro C. <mau...@gm...> - 2009年01月13日 23:20:51
Dear Wayne,
2009年1月13日 Hajas, Wayne <Way...@df...>:
>
> Should I expect IDLE to work with matplotlib? Should I try and figure out
> Ipython instead?
>
Definetely, IPython *is* the environment to work with Python plus
Matplotlib, as it already includes built-in support for interactive
use of MPL (and in general too, as IPython offers a lot more resources
than IDLE).
Hope this helps!
Best regards,
-- 
Dr. Mauro J. Cavalcanti
Ecoinformatics Studio
P.O. Box 46521, CEP 20551-970
Rio de Janeiro, RJ, BRASIL
E-mail: mau...@gm...
Web: http://studio.infobio.net
Linux Registered User #473524 * Ubuntu User #22717
"Life is complex. It consists of real and imaginary parts."
From: Massimo S. <mas...@un...> - 2009年01月13日 22:48:33
I have the vague remembrance of the fact that IDLE does not play well with matplotlib. Can you try to run the program from the command line and see if it gives the same error?
m.
--
Massimo Sandal , Ph.D.
University of Bologna
Department of Biochemistry "G.Moruzzi"
snail mail:
Via Irnerio 48, 40126 Bologna, Italy
email:
mas...@un...
web:
http://www.biocfarm.unibo.it/samori/people/sandal.html
tel: +39-051-2094388
fax: +39-051-2094387
-----Messaggio originale-----
Da: Hajas, Wayne [mailto:Way...@df...]
Inviato: mar 13/01/2009 21.05
A: mat...@li...
Oggetto: [Matplotlib-users] Newbie question/closing a figure-window
 
I'm just getting into matplotlib and python. My apologies if I just
haven't found the obvious documentation. 
I am running XP/Enthought Python 2.5/Idle/matplotlib 0.98.5.2
I run one of the scripts from the tutorial:
	import numpy as np
	import matplotlib.pyplot as plt
	mu, sigma = 100, 15
	x = mu + sigma * np.random.randn(10000)
	# the histogram of the data
	n, bins, patches = plt.hist(x, 50, normed=1, facecolor='g',
alpha=0.75)
	plt.xlabel('Smarts')
	plt.ylabel('Probability')
	plt.title('Histogram of IQ')
	plt.text(60, .025, r'$\mu=100,\ \sigma=15$')
	plt.axis([40, 160, 0, 0.03])
	plt.grid(True)
	plt.show()
A window with the figure appears on my screen. It looks very nice. But
now my PYTHON-Shell screen is dead.
I can go to the figure window. I right click on the upper-border to
close the window. I get the following error message on the
PYTHON-Shell.
	Exception in Tkinter callback
	Traceback (most recent call last):
	 File "C:\Python25\lib\lib-tk\Tkinter.py", line 1403, in
__call__
	 return self.func(*args)
	 File "C:\Python25\lib\idlelib\MultiCall.py", line 151, in
handler
	 r = l[i](event)
	 File "C:\Python25\lib\idlelib\ScriptBinding.py", line 166, in
run_module_event
	 interp.runcode(code)
	 File "C:\Python25\lib\idlelib\PyShell.py", line 701, in
runcode
	 self.interp.restart_subprocess()
	AttributeError: ModifiedInterpreter instance has no attribute
'interp'
And the shell-window is still dead. I can't do anything else until I
close all my Python windows.
Is there a better way to close the figure-window?
Should I expect IDLE to work with matplotlib? Should I try and figure
out Ipython instead?
Should I look for a Tkinter installation? My current version is
Revision: 50704?
Any help or suggestions are appreciated.
Wayne Hajas
Pacific Biological Station
3190 Hammond Bay Road
Nanaimo, BC
Canada
V9T 6N7
way...@df... <mailto:ha...@df...> 
(250)756-7367
From: Darren D. <dsd...@gm...> - 2009年01月13日 21:09:01
Perhaps the interpolation needs to be set to 'nearest'?
On Tue, Jan 13, 2009 at 3:33 PM, John Hunter <jd...@gm...> wrote:
> On Tue, Jan 13, 2009 at 12:16 PM, Martinho MA <mm...@ua...> wrote:
> > Hello,
> > I have a problem saving png files created from data with missing values.
> > The matlab and pylab outputs are very different... pylab resolution is
> > poorer !?
> >
> > the saving commands from matlab and python are similar:
> >
> > matlab:
> > >>print -dpng -r80 test_matlab.png
> >
> > python:
> > >>pylab.savefig('test_pylab.png',dpi=80)
> >
> >
> > look at the examples:
> > http://neptuno.fis.ua.pt/tmp/comp.html
> >
> > Can I get the pylab output with the quality of test_matlab.png?
>
>
> Without seeing any code or knowing anything about your matplotlib
> version -- it is hard to help.
>
>
> http://matplotlib.sourceforge.net/faq/troubleshooting_faq.html#report-a-problem
>
> JDH
>
>
> ------------------------------------------------------------------------------
> This SF.net email is sponsored by:
> SourcForge Community
> SourceForge wants to tell your story.
> http://p.sf.net/sfu/sf-spreadtheword
> _______________________________________________
> Matplotlib-users mailing list
> Mat...@li...
> https://lists.sourceforge.net/lists/listinfo/matplotlib-users
>
From: John H. <jd...@gm...> - 2009年01月13日 20:33:19
On Tue, Jan 13, 2009 at 12:16 PM, Martinho MA <mm...@ua...> wrote:
> Hello,
> I have a problem saving png files created from data with missing values.
> The matlab and pylab outputs are very different... pylab resolution is
> poorer !?
>
> the saving commands from matlab and python are similar:
>
> matlab:
> >>print -dpng -r80 test_matlab.png
>
> python:
> >>pylab.savefig('test_pylab.png',dpi=80)
>
>
> look at the examples:
> http://neptuno.fis.ua.pt/tmp/comp.html
>
> Can I get the pylab output with the quality of test_matlab.png?
Without seeing any code or knowing anything about your matplotlib
version -- it is hard to help.
 http://matplotlib.sourceforge.net/faq/troubleshooting_faq.html#report-a-problem
JDH
From: Hajas, W. <Way...@df...> - 2009年01月13日 20:17:49
I'm just getting into matplotlib and python. My apologies if I just
haven't found the obvious documentation. 
I am running XP/Enthought Python 2.5/Idle/matplotlib 0.98.5.2
I run one of the scripts from the tutorial:
	import numpy as np
	import matplotlib.pyplot as plt
	mu, sigma = 100, 15
	x = mu + sigma * np.random.randn(10000)
	# the histogram of the data
	n, bins, patches = plt.hist(x, 50, normed=1, facecolor='g',
alpha=0.75)
	plt.xlabel('Smarts')
	plt.ylabel('Probability')
	plt.title('Histogram of IQ')
	plt.text(60, .025, r'$\mu=100,\ \sigma=15$')
	plt.axis([40, 160, 0, 0.03])
	plt.grid(True)
	plt.show()
A window with the figure appears on my screen. It looks very nice. But
now my PYTHON-Shell screen is dead.
I can go to the figure window. I right click on the upper-border to
close the window. I get the following error message on the
PYTHON-Shell.
	Exception in Tkinter callback
	Traceback (most recent call last):
	 File "C:\Python25\lib\lib-tk\Tkinter.py", line 1403, in
__call__
	 return self.func(*args)
	 File "C:\Python25\lib\idlelib\MultiCall.py", line 151, in
handler
	 r = l[i](event)
	 File "C:\Python25\lib\idlelib\ScriptBinding.py", line 166, in
run_module_event
	 interp.runcode(code)
	 File "C:\Python25\lib\idlelib\PyShell.py", line 701, in
runcode
	 self.interp.restart_subprocess()
	AttributeError: ModifiedInterpreter instance has no attribute
'interp'
And the shell-window is still dead. I can't do anything else until I
close all my Python windows.
Is there a better way to close the figure-window?
Should I expect IDLE to work with matplotlib? Should I try and figure
out Ipython instead?
Should I look for a Tkinter installation? My current version is
Revision: 50704?
Any help or suggestions are appreciated.
Wayne Hajas
Pacific Biological Station
3190 Hammond Bay Road
Nanaimo, BC
Canada
V9T 6N7
way...@df... <mailto:ha...@df...> 
(250)756-7367
From: Martinho MA <mm...@ua...> - 2009年01月13日 20:17:18
Hello,
I have a problem saving png files created from data with missing values.
The matlab and pylab outputs are very different... pylab resolution is 
poorer !?
the saving commands from matlab and python are similar:
matlab:
 >>print -dpng -r80 test_matlab.png
python:
 >>pylab.savefig('test_pylab.png',dpi=80)
look at the examples:
http://neptuno.fis.ua.pt/tmp/comp.html
Can I get the pylab output with the quality of test_matlab.png?
Thank you
mma
From: Jeff W. <js...@fa...> - 2009年01月13日 19:33:11
Mauro Cavalcanti wrote:
> Dear Jeff,
>
> Sorry for posting this again, but I suppose my previous message may
> have got lost among many others.
>
> I would like to ask you if there are plans to release, as a regular
> MS-Windows self-installation file, the lastest version of Basemap
> (0.99.3). It happens that my biogeographic application is due to
> public release tomorrow (I will annnounce it here too) and it makes
> use of some critical functionality that is available only in the
> lastest Basemap version (0.99.3). The online documentation for Basemap
> already indicates that the current version is 0.99.3, but the .latest
> exe files in the SF repository are still from version 0.99.2.
>
> Best regards,
>
> 
Mauro: I'll try to get a new release tomorrow (releasing the source is 
easy, finding the time to make a windows installer is more difficult, 
since I have to borrow someone else's windows box).
-Jeff
-- 
Jeffrey S. Whitaker Phone : (303)497-6313
Meteorologist FAX : (303)497-6449
NOAA/OAR/PSD R/PSD1 Email : Jef...@no...
325 Broadway Office : Skaggs Research Cntr 1D-113
Boulder, CO, USA 80303-3328 Web : http://tinyurl.com/5telg
From: Mauro C. <mau...@gm...> - 2009年01月13日 19:26:06
Dear Jeff,
Sorry for posting this again, but I suppose my previous message may
have got lost among many others.
I would like to ask you if there are plans to release, as a regular
MS-Windows self-installation file, the lastest version of Basemap
(0.99.3). It happens that my biogeographic application is due to
public release tomorrow (I will annnounce it here too) and it makes
use of some critical functionality that is available only in the
lastest Basemap version (0.99.3). The online documentation for Basemap
already indicates that the current version is 0.99.3, but the .latest
exe files in the SF repository are still from version 0.99.2.
Best regards,
-- 
Dr. Mauro J. Cavalcanti
Ecoinformatics Studio
P.O. Box 46521, CEP 20551-970
Rio de Janeiro, RJ, BRASIL
E-mail: mau...@gm...
Web: http://studio.infobio.net
Linux Registered User #473524 * Ubuntu User #22717
"Life is complex. It consists of real and imaginary parts."
From: Mauro C. <mau...@gm...> - 2009年01月13日 19:21:23
Dear Sandro,
After sending you the previous message, I just decided to try one
little thing: I used "easy_install -U matplotlib" and then the latest
version (0.98.5.2) was correctly retrieved from the SF repository and
properly installed (before followed the instructions you provided
yesterday, this procedure did not result). And then I now have MPL
completely working again on my Ubuntu Intrepid box!
Thank you very much for your attention.
With best regards,
2009年1月13日 Sandro Tosi <mo...@de...>:
> Well, honestly I don't know and I don't want to invest too much time
> on this: I'll provide the compiled packages (even if still temporary,
> waiting for Matplotlib developers to release 0.98.5.3) tomorrow, and
> then I'll post the location on the list. They will be for Debian Sid,
> so they might not work "out of the box" and you might need to get
> other packages from Debian and install into Ubuntu.
>
> Regards,
> --
> Sandro Tosi (aka morph, morpheus, matrixhasu)
> My website: http://matrixhasu.altervista.org/
> Me at Debian: http://wiki.debian.org/SandroTosi
>
-- 
Dr. Mauro J. Cavalcanti
Ecoinformatics Studio
P.O. Box 46521, CEP 20551-970
Rio de Janeiro, RJ, BRASIL
E-mail: mau...@gm...
Web: http://studio.infobio.net
Linux Registered User #473524 * Ubuntu User #22717
"Life is complex. It consists of real and imaginary parts."
From: Sandro T. <mo...@de...> - 2009年01月13日 18:43:09
Hello Fabio,
On Tue, Jan 13, 2009 at 18:55, Fabio Tonti <ft...@gm...> wrote:
> Hello everyone,
>
> I need some help for building matplotlib from source. I'm using Debian sid
> on 64bit.
> I had errors when trying to build version 0.98.5.1 and now it's not gone
> with 0.98.5.2, so I hope mailing is appropriate.
> I've appended the whole log.
I'm the Debian maintainer of matplotlib, so in case of problem with
the package it's better to get directly to me.
But it seems you're building from source without the debian
"architecture" around: well, my suggestion is, use it :)
If you know how to do, the debian code is at [1] (you still have to
download the tarball yourself), if not tomorrow I'll upload to a
temporary place the 0.98.5.2 version (source packages + amd64
version); note that I was not encouraged to upload to Debian.
[1] svn://svn.debian.org/svn/python-modules/packages/matplotlib/trunk/debian
Regards,
-- 
Sandro Tosi (aka morph, morpheus, matrixhasu)
My website: http://matrixhasu.altervista.org/
Me at Debian: http://wiki.debian.org/SandroTosi
From: Sandro T. <mo...@de...> - 2009年01月13日 18:29:06
On Tue, Jan 13, 2009 at 13:20, Mauro Cavalcanti <mau...@gm...> wrote:
> Dear Sandro,
>
> First of all, I apologize for the delay in replying -- yesterday was
> already late night here and I also had to fight (???) a "kernel panic"
> in my Linux box the cause of which is not yet clear (I also had it
> under Ubuntu Hardy and now it appeared in Intrepid -- under Hardy, I
> substituted my only RAM chip and the problem disappeared, but now I
> think the problem may be related to overheating -- it is the hottest
> tropical summer here down under!).
>
> Well, after following the steps you provided for creating the Debian
> package for MPL, and installing all required dependencies, I still
> could not create the package -- the reason is that the program keeps
> complaining about an older version of python-sphinx, even if I
> upgraded to the latest version it using easy_install... Maybe I will
> have to build sphinx from souce too?
Well, honestly I don't know and I don't want to invest too much time
on this: I'll provide the compiled packages (even if still temporary,
waiting for Matplotlib developers to release 0.98.5.3) tomorrow, and
then I'll post the location on the list. They will be for Debian Sid,
so they might not work "out of the box" and you might need to get
other packages from Debian and install into Ubuntu.
Regards,
-- 
Sandro Tosi (aka morph, morpheus, matrixhasu)
My website: http://matrixhasu.altervista.org/
Me at Debian: http://wiki.debian.org/SandroTosi
From: Fabio T. <ft...@gm...> - 2009年01月13日 17:55:26
============================================================================
BUILDING MATPLOTLIB
 matplotlib: 0.98.5.2
 python: 2.5.2 (r252:60911, Jan 4 2009, 21:59:32) [GCC
 4.3.2]
 platform: linux2
REQUIRED DEPENDENCIES
 numpy: 1.1.1
 freetype2: found, but unknown version (no pkg-config)
 * WARNING: Could not find 'freetype2' headers in any
 * of '/usr/local/include', '/usr/include', '.',
 * '/usr/local/include/freetype2',
 * '/usr/include/freetype2', './freetype2'.
OPTIONAL BACKEND DEPENDENCIES
 libpng: found, but unknown version (no pkg-config)
 Tkinter: no
 * Using default library and include directories for
 * Tcl and Tk because a Tk window failed to open.
 * You may need to define DISPLAY for Tk to work so
 * that setup can determine where your libraries are
 * located. Tkinter present, but header files are not
 * found. You may need to install development
 * packages.
 wxPython: no
 * WXAgg's accelerator requires `wx-config'. The
 * `wx-config' executable could not be located in any
 * directory of the PATH environment variable. If you
 * want to build WXAgg, and wx-config is in some
 * other location or has some other name, set the
 * WX_CONFIG environment variable to the full path of
 * the executable like so: export WX_CONFIG=/usr/lib
 * /wxPython-2.6.1.0-gtk2-unicode/bin/wx-config
 * You may need to install 'dev' package(s) to
 * provide header files.
 Gtk+: no
 * Could not find Gtk+ headers in any of
 * '/usr/local/include', '/usr/include', '.'
 Mac OS X native: no
 Qt: no
 Qt4: no
 Cairo: 1.4.12
OPTIONAL DATE/TIMEZONE DEPENDENCIES
 datetime: present, version unknown
 dateutil: 1.4.1
 pytz: 2008h
OPTIONAL USETEX DEPENDENCIES
 dvipng: no
 ghostscript: 8.63
 latex: 3.141592
 pdftops: 3.00
[Edit setup.cfg to suppress the above messages]
============================================================================
pymods ['pylab']
packages ['matplotlib', 'matplotlib.backends', 'matplotlib.projections', 'mpl_toolkits', 'matplotlib.numerix', 'matplotlib.numerix.mlab', 'matplotlib.numerix.ma', 'matplotlib.numerix.npyma', 'matplotlib.numerix.linear_algebra', 'matplotlib.numerix.random_array', 'matplotlib.numerix.fft', 'matplotlib.delaunay']
running build
running build_py
copying lib/matplotlib/mpl-data/matplotlibrc -> build/lib.linux-x86_64-2.5/matplotlib/mpl-data
copying lib/matplotlib/mpl-data/matplotlib.conf -> build/lib.linux-x86_64-2.5/matplotlib/mpl-data
running build_ext
building 'matplotlib.ft2font' extension
gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fPIC -I/usr/lib/python2.5/site-packages/numpy/core/include -I/usr/local/include -I/usr/include -I. -I/usr/lib/python2.5/site-packages/numpy/core/include/freetype2 -I/usr/local/include/freetype2 -I/usr/include/freetype2 -I./freetype2 -I/usr/include/python2.5 -c src/ft2font.cpp -o build/temp.linux-x86_64-2.5/src/ft2font.o
cc1plus: warning: command line option "-Wstrict-prototypes" is valid for Ada/C/ObjC but not for C++
In file included from ./CXX/Extensions.hxx:48,
 from src/ft2font.h:4,
 from src/ft2font.cpp:1:
./CXX/WrapPython.h:42:20: error: Python.h: No such file or directory
In file included from ./CXX/Extensions.hxx:50,
 from src/ft2font.h:4,
 from src/ft2font.cpp:1:
./CXX/Config.hxx:112:2: error: #error not defined PY_MAJOR_VERSION
In file included from src/ft2font.cpp:1:
src/ft2font.h:13:22: error: ft2build.h: No such file or directory
src/ft2font.h:14:10: error: #include expects "FILENAME" or <FILENAME>
src/ft2font.h:15:10: error: #include expects "FILENAME" or <FILENAME>
src/ft2font.h:16:10: error: #include expects "FILENAME" or <FILENAME>
src/ft2font.h:17:10: error: #include expects "FILENAME" or <FILENAME>
src/ft2font.h:18:10: error: #include expects "FILENAME" or <FILENAME>
In file included from /usr/lib/python2.5/site-packages/numpy/core/include/numpy/arrayobject.h:14,
 from src/ft2font.cpp:6:
/usr/lib/python2.5/site-packages/numpy/core/include/numpy/ndarrayobject.h:100:2: error: #error Must use Python with unicode enabled.
In file included from ./CXX/Exception.hxx:44,
 from ./CXX/Objects.hxx:44,
 from ./CXX/Extensions.hxx:51,
 from src/ft2font.h:4,
 from src/ft2font.cpp:1:
./CXX/IndirectPythonInterface.hxx:50: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:51: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:52: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:53: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:55: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:56: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:57: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:58: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:59: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:60: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:61: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:62: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:63: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:64: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:65: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:66: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:67: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:68: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:69: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:70: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:71: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:72: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:73: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:74: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:75: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:76: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:81: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:93: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:99: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:100: error: ‘PyObject’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:100: error: ‘o’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:102: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:103: error: ‘PyObject’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:103: error: ‘op’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:105: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:106: error: ‘PyObject’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:106: error: ‘op’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:108: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:109: error: ‘PyObject’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:109: error: ‘op’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:111: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:112: error: ‘PyObject’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:112: error: ‘op’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:114: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:115: error: ‘PyObject’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:115: error: ‘op’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:117: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:118: error: ‘PyObject’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:118: error: ‘op’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:120: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:121: error: ‘PyObject’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:121: error: ‘op’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:123: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:124: error: ‘PyObject’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:124: error: ‘op’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:126: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:127: error: ‘PyObject’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:127: error: ‘op’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:129: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:130: error: ‘PyObject’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:130: error: ‘op’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:132: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:133: error: ‘PyObject’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:133: error: ‘op’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:135: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:136: error: ‘PyObject’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:136: error: ‘op’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:138: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:139: error: redefinition of ‘bool Py::_List_Check’
./CXX/IndirectPythonInterface.hxx:100: error: ‘bool Py::_List_Check’ previously defined here
./CXX/IndirectPythonInterface.hxx:139: error: ‘PyObject’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:139: error: ‘op’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:141: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:142: error: ‘PyObject’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:142: error: ‘op’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:144: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:145: error: ‘PyObject’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:145: error: ‘op’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:147: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:148: error: ‘PyObject’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:148: error: ‘op’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:150: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:151: error: ‘PyObject’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:151: error: ‘op’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:153: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:154: error: ‘PyObject’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:154: error: ‘op’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:156: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:157: error: ‘PyObject’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:157: error: ‘op’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:159: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:160: error: ‘PyObject’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:160: error: ‘op’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:162: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:163: error: ‘PyObject’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:163: error: ‘op’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:165: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:166: error: ‘PyObject’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:166: error: ‘v’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:168: error: expected constructor, destructor, or type conversion before ‘*’ token
./CXX/IndirectPythonInterface.hxx:169: error: ‘PyObject’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:169: error: ‘op’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:187: error: variable or field ‘_XINCREF’ declared void
./CXX/IndirectPythonInterface.hxx:187: error: ‘PyObject’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:187: error: ‘op’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:188: error: variable or field ‘_XDECREF’ declared void
./CXX/IndirectPythonInterface.hxx:188: error: ‘PyObject’ was not declared in this scope
./CXX/IndirectPythonInterface.hxx:188: error: ‘op’ was not declared in this scope
In file included from ./CXX/Objects.hxx:44,
 from ./CXX/Extensions.hxx:51,
 from src/ft2font.h:4,
 from src/ft2font.cpp:1:
./CXX/Exception.hxx:70: error: expected `)' before ‘*’ token
./CXX/Exception.hxx:75: error: expected `)' before ‘*’ token
./CXX/Exception.hxx: In constructor ‘Py::Exception::Exception(const std::string&)’:
./CXX/Exception.hxx:67: error: ‘_Exc_RuntimeError’ is not a member of ‘Py’
./CXX/Exception.hxx:67: error: ‘PyErr_SetString’ was not declared in this scope
./CXX/Exception.hxx: In member function ‘void Py::Exception::clear()’:
./CXX/Exception.hxx:80: error: ‘PyErr_Clear’ was not declared in this scope
./CXX/Exception.hxx: In constructor ‘Py::TypeError::TypeError(const std::string&)’:
./CXX/Exception.hxx:122: error: ‘_Exc_TypeError’ is not a member of ‘Py’
./CXX/Exception.hxx:122: error: ‘PyErr_SetString’ was not declared in this scope
./CXX/Exception.hxx: In constructor ‘Py::IndexError::IndexError(const std::string&)’:
./CXX/Exception.hxx:132: error: ‘_Exc_IndexError’ is not a member of ‘Py’
./CXX/Exception.hxx:132: error: ‘PyErr_SetString’ was not declared in this scope
./CXX/Exception.hxx: In constructor ‘Py::AttributeError::AttributeError(const std::string&)’:
./CXX/Exception.hxx:142: error: ‘_Exc_AttributeError’ is not a member of ‘Py’
./CXX/Exception.hxx:142: error: ‘PyErr_SetString’ was not declared in this scope
./CXX/Exception.hxx: In constructor ‘Py::NameError::NameError(const std::string&)’:
./CXX/Exception.hxx:152: error: ‘_Exc_NameError’ is not a member of ‘Py’
./CXX/Exception.hxx:152: error: ‘PyErr_SetString’ was not declared in this scope
./CXX/Exception.hxx: In constructor ‘Py::RuntimeError::RuntimeError(const std::string&)’:
./CXX/Exception.hxx:162: error: ‘_Exc_RuntimeError’ is not a member of ‘Py’
./CXX/Exception.hxx:162: error: ‘PyErr_SetString’ was not declared in this scope
./CXX/Exception.hxx: In constructor ‘Py::SystemError::SystemError(const std::string&)’:
./CXX/Exception.hxx:172: error: ‘_Exc_SystemError’ is not a member of ‘Py’
./CXX/Exception.hxx:172: error: ‘PyErr_SetString’ was not declared in this scope
./CXX/Exception.hxx: In constructor ‘Py::KeyError::KeyError(const std::string&)’:
./CXX/Exception.hxx:182: error: ‘_Exc_KeyError’ is not a member of ‘Py’
./CXX/Exception.hxx:182: error: ‘PyErr_SetString’ was not declared in this scope
./CXX/Exception.hxx: In constructor ‘Py::ValueError::ValueError(const std::string&)’:
./CXX/Exception.hxx:193: error: ‘_Exc_ValueError’ is not a member of ‘Py’
./CXX/Exception.hxx:193: error: ‘PyErr_SetString’ was not declared in this scope
./CXX/Exception.hxx: In constructor ‘Py::OverflowError::OverflowError(const std::string&)’:
./CXX/Exception.hxx:203: error: ‘_Exc_OverflowError’ is not a member of ‘Py’
./CXX/Exception.hxx:203: error: ‘PyErr_SetString’ was not declared in this scope
./CXX/Exception.hxx: In constructor ‘Py::ZeroDivisionError::ZeroDivisionError(const std::string&)’:
./CXX/Exception.hxx:213: error: ‘_Exc_ZeroDivisionError’ is not a member of ‘Py’
./CXX/Exception.hxx:213: error: ‘PyErr_SetString’ was not declared in this scope
./CXX/Exception.hxx: In constructor ‘Py::FloatingPointError::FloatingPointError(const std::string&)’:
./CXX/Exception.hxx:223: error: ‘_Exc_FloatingPointError’ is not a member of ‘Py’
./CXX/Exception.hxx:223: error: ‘PyErr_SetString’ was not declared in this scope
./CXX/Exception.hxx: In constructor ‘Py::MemoryError::MemoryError(const std::string&)’:
./CXX/Exception.hxx:233: error: ‘_Exc_MemoryError’ is not a member of ‘Py’
./CXX/Exception.hxx:233: error: ‘PyErr_SetString’ was not declared in this scope
./CXX/Exception.hxx: In constructor ‘Py::SystemExit::SystemExit(const std::string&)’:
./CXX/Exception.hxx:243: error: ‘_Exc_SystemExit’ is not a member of ‘Py’
./CXX/Exception.hxx:243: error: ‘PyErr_SetString’ was not declared in this scope
In file included from ./CXX/Extensions.hxx:51,
 from src/ft2font.h:4,
 from src/ft2font.cpp:1:
./CXX/Objects.hxx: At global scope:
./CXX/Objects.hxx:66: error: expected initializer before ‘*’ token
./CXX/Objects.hxx:74: error: expected initializer before ‘*’ token
./CXX/Objects.hxx:150: error: ISO C++ forbids declaration of ‘PyObject’ with no type
./CXX/Objects.hxx:150: error: expected ‘;’ before ‘*’ token
./CXX/Objects.hxx:154: error: ‘PyObject’ has not been declared
./CXX/Objects.hxx:194: error: expected `)' before ‘*’ token
src/ft2font.cpp:1931: error: expected `}' at end of input
./CXX/Objects.hxx: In member function ‘void Py::Object::set(int*, bool)’:
./CXX/Objects.hxx:157: error: ‘p’ was not declared in this scope
./CXX/Objects.hxx:160: error: ‘_XINCREF’ is not a member of ‘Py’
./CXX/Objects.hxx: In member function ‘void Py::Object::release()’:
./CXX/Objects.hxx:167: error: ‘_XDECREF’ is not a member of ‘Py’
./CXX/Objects.hxx:167: error: ‘p’ was not declared in this scope
./CXX/Objects.hxx: In member function ‘void Py::Object::validate()’:
./CXX/Objects.hxx:174: error: ‘p’ was not declared in this scope
./CXX/Objects.hxx:174: error: ‘accepts’ was not declared in this scope
./CXX/Objects.hxx:177: error: ‘PyErr_Occurred’ was not declared in this scope
./CXX/Objects.hxx: At global scope:
./CXX/Objects.hxx:190: error: expected unqualified-id at end of input
./CXX/Objects.hxx:190: error: expected `}' at end of input
error: command 'gcc' failed with exit status 1
From: Jeff W. <js...@fa...> - 2009年01月13日 16:31:30
Jon Blower wrote:
> Hi all,
>
> I'm a matplotlib newbie and have recently installed matplotlib as part
> of the Python(x,y) distribution for Windows. I want to do some image
> manipulation (e.g. basemap.warpimage()) and my initial installation
> didn't have the Python Imaging Library (PIL) installed, so I installed
> this via easy_install:
>
> easy_install PIL
>
> This worked, but it was installed in such a way that the import command
>
> from PIL import Image
>
> doesn't work (it seems that "import Image" works instead). This means
> that basemap.warpimage() does not work because it expects to be able
> to import PIL through the former expression. I can try to install PIL
> some other way, but does this indicate that the basemap module should
> try both ways of importing PIL, as different users might have
> different setups? Is there a quick fix that I could apply?
>
> (Apologies if this question has been asked before - I did some
> Googling and didn't find anything.)
>
> Regards, Jon
>
> 
Jon: It seems like PIL is not "setuptools-aware"...
http://mail.python.org/pipermail/image-sig/2007-May/004451.html
PIL does not get installed correctly using setuptools. You'll need to 
install the old-fashioned way, i.e. "python setup.py install".
-Jeff
-- 
Jeffrey S. Whitaker Phone : (303)497-6313
Meteorologist FAX : (303)497-6449
NOAA/OAR/PSD R/PSD1 Email : Jef...@no...
325 Broadway Office : Skaggs Research Cntr 1D-113
Boulder, CO, USA 80303-3328 Web : http://tinyurl.com/5telg
From: Mauro C. <mau...@gm...> - 2009年01月13日 16:30:23
Dear Dr. Blower,
I would by all means suggest the Enthought Python Distribution
(http://www.enthought.com/) in place of Python(x,y). EPD already
includes PIL, MPL and Basemap (although in a somewhat "abridged" and
outdated version, but this is just a matter of upgrading).
Hope this helps.
Best regards,
2009年1月13日 Jon Blower <j.d...@re...>:
> Hi all,
>
> I'm a matplotlib newbie and have recently installed matplotlib as part
> of the Python(x,y) distribution for Windows. I want to do some image
> manipulation (e.g. basemap.warpimage()) and my initial installation
> didn't have the Python Imaging Library (PIL) installed, so I installed
> this via easy_install:
>
> easy_install PIL
>
> This worked, but it was installed in such a way that the import command
>
> from PIL import Image
>
> doesn't work (it seems that "import Image" works instead). This means
> that basemap.warpimage() does not work because it expects to be able
> to import PIL through the former expression. I can try to install PIL
> some other way, but does this indicate that the basemap module should
> try both ways of importing PIL, as different users might have
> different setups? Is there a quick fix that I could apply?
>
> (Apologies if this question has been asked before - I did some
> Googling and didn't find anything.)
>
> Regards, Jon
>
> --
> Dr Jon Blower
> Technical Director, Reading e-Science Centre
> Environmental Systems Science Centre
> University of Reading
> Harry Pitt Building, 3 Earley Gate
> Reading RG6 6AL. UK
> Tel: +44 (0)118 378 5213
> Fax: +44 (0)118 378 6413
> j.d...@re...
> http://www.nerc-essc.ac.uk/People/Staff/Blower_J.htm
>
> ------------------------------------------------------------------------------
> This SF.net email is sponsored by:
> SourcForge Community
> SourceForge wants to tell your story.
> http://p.sf.net/sfu/sf-spreadtheword
> _______________________________________________
> Matplotlib-users mailing list
> Mat...@li...
> https://lists.sourceforge.net/lists/listinfo/matplotlib-users
>
-- 
Dr. Mauro J. Cavalcanti
Ecoinformatics Studio
P.O. Box 46521, CEP 20551-970
Rio de Janeiro, RJ, BRASIL
E-mail: mau...@gm...
Web: http://studio.infobio.net
Linux Registered User #473524 * Ubuntu User #22717
"Life is complex. It consists of real and imaginary parts."
From: Jon B. <j.d...@re...> - 2009年01月13日 16:19:34
Hi all,
I'm a matplotlib newbie and have recently installed matplotlib as part
of the Python(x,y) distribution for Windows. I want to do some image
manipulation (e.g. basemap.warpimage()) and my initial installation
didn't have the Python Imaging Library (PIL) installed, so I installed
this via easy_install:
easy_install PIL
This worked, but it was installed in such a way that the import command
from PIL import Image
doesn't work (it seems that "import Image" works instead). This means
that basemap.warpimage() does not work because it expects to be able
to import PIL through the former expression. I can try to install PIL
some other way, but does this indicate that the basemap module should
try both ways of importing PIL, as different users might have
different setups? Is there a quick fix that I could apply?
(Apologies if this question has been asked before - I did some
Googling and didn't find anything.)
Regards, Jon
-- 
Dr Jon Blower
Technical Director, Reading e-Science Centre
Environmental Systems Science Centre
University of Reading
Harry Pitt Building, 3 Earley Gate
Reading RG6 6AL. UK
Tel: +44 (0)118 378 5213
Fax: +44 (0)118 378 6413
j.d...@re...
http://www.nerc-essc.ac.uk/People/Staff/Blower_J.htm
From: Jouni K. S. <jk...@ik...> - 2009年01月13日 15:12:36
"Ken Schutte" <kts...@gm...> writes:
> I'm trying to add some more complex LaTeX-rendered equations into a a
> figure, and having some problems. I've been trying various things
> with 'usetex', but it seems the problem might be that I can't seem to
> write the LaTex code on a single line.
It seems that text objects containing newlines are not passed to LaTeX
correctly. I suspect this might be an interaction with a (non-usetex)
feature where the lines of a multiline string are aligned separately,
e.g.:
text(0,0,'''very long line here
foobar
baz''', ha='center')
You should be able to work around this particular problem by not using
any newlines, but this example has another problem:
> \begin{equation*}
> x(t) =
> \begin{cases}
> 1, \quad & t \ge 0 \\
> 0, & t < 0
> \end{cases}
> \end{equation*}
You need to use the amsmath package. The (totally unsupported) way to do
this is use the text.latex.preamble setting:
text.latex.preamble : \usepackage{amsmath}
 # IMPROPER USE OF THIS FEATURE WILL LEAD TO LATEX FAILURES
 # AND IS THEREFORE UNSUPPORTED. PLEASE DO NOT ASK FOR HELP
 # IF THIS FEATURE DOES NOT DO WHAT YOU EXPECT IT TO.
After adding that setting, this works for me:
In [1]: t = r'''
 ...: \begin{equation*}
 ...: x(t) =
 ...: \begin{cases}
 ...: 1, \quad & t \ge 0 \\
 ...: 0, & t < 0
 ...: \end{cases}
 ...: \end{equation*}
 ...: '''
In [2]: text(0,0,t.replace('\n',' '))
Out[2]: <matplotlib.text.Text object at 0xab82a50>
-- 
Jouni K. Seppänen
http://www.iki.fi/jks
From: Darren D. <dsd...@gm...> - 2009年01月13日 13:38:41
On Tue, Jan 13, 2009 at 6:53 AM, Ken Schutte <kts...@gm...> wrote:
> I'm trying to add some more complex LaTeX-rendered equations into a a
> figure, and having some problems. I've been trying various things
> with 'usetex', but it seems the problem might be that I can't seem to
> write the LaTex code on a single line.
>
> For example, can you not do:
> ax.text(0,0,r"""
> ...
> ...
> """)
>
> ?
>
> One example that I'm trying is the following, using 'cases'. I'll
> paste a complete .tex file:
>
> \documentclass{article}
> \pagestyle{empty}
> \usepackage{amsmath}
> \begin{document}
>
> \begin{equation*}
> x(t) =
> \begin{cases}
> 1, \quad & t \ge 0 \\
> 0, & t < 0
> \end{cases}
> \end{equation*}
>
> \end{document}
>
>
> Any suggestions? I think this works with '\displaystyle' inside
> single '$', but you need multiple lines... ?
>
Hi Ken,
I'm sorry, multi-line input is currently not supported. I've got a lot of
other projects on my plate and dont intend to implement such a feature
myself, but I'd have a look at a patch if one were submitted that wasn't too
invasive. The usetex stuff was pretty hairy to get working across platforms,
so I'm reluctant to mess with it.
Darren
From: Ken S. <kts...@gm...> - 2009年01月13日 13:06:37
I'm trying to add some more complex LaTeX-rendered equations into a a
figure, and having some problems. I've been trying various things
with 'usetex', but it seems the problem might be that I can't seem to
write the LaTex code on a single line.
For example, can you not do:
ax.text(0,0,r"""
...
...
""")
?
One example that I'm trying is the following, using 'cases'. I'll
paste a complete .tex file:
\documentclass{article}
\pagestyle{empty}
\usepackage{amsmath}
\begin{document}
\begin{equation*}
x(t) =
\begin{cases}
1, \quad & t \ge 0 \\
0, & t < 0
\end{cases}
\end{equation*}
\end{document}
Any suggestions? I think this works with '\displaystyle' inside
single '$', but you need multiple lines... ?
thanks,
Ken
From: Mauro C. <mau...@gm...> - 2009年01月13日 12:49:14
Dear Sandro,
First of all, I apologize for the delay in replying -- yesterday was
already late night here and I also had to fight (???) a "kernel panic"
in my Linux box the cause of which is not yet clear (I also had it
under Ubuntu Hardy and now it appeared in Intrepid -- under Hardy, I
substituted my only RAM chip and the problem disappeared, but now I
think the problem may be related to overheating -- it is the hottest
tropical summer here down under!).
Well, after following the steps you provided for creating the Debian
package for MPL, and installing all required dependencies, I still
could not create the package -- the reason is that the program keeps
complaining about an older version of python-sphinx, even if I
upgraded to the latest version it using easy_install... Maybe I will
have to build sphinx from souce too?
With best regards,
2009年1月12日 Sandro Tosi <mo...@de...>:
> On Mon, Jan 12, 2009 at 19:52, Mauro Cavalcanti <mau...@gm...> wrote:
>> I must say I feel truly honoured. I never expected my humble complaint
>> would merit the attention of one of the Debian maintainters!
>
> eheh, well, we are not some sort of gods or what: we talk to mortals now :D
>
>> I will follow the directions you provided - as I understood, they will
>> result in the creation of a deb package for the latest version of
>> Matplotlib? This will be great!
>
> Yes: Ubuntu is a Debian-based distribution, so once you'll have the
> deb files (built on your ubuntu box) it enough to
>
> sudo dpkg -i python-matplotlib*.deb
>
> and it will install them
>
>> I will report the results to you (and the Matplotlib-users lists) as
>> soon as possible.
>
> Great. The only problem I see is that there are a lot of caveats in
> building packages, and you can face some corner case (I couldn't cope
> in my uber-fast introduction to deb building :) ).
>
> Regards,
> --
> Sandro Tosi (aka morph, morpheus, matrixhasu)
> My website: http://matrixhasu.altervista.org/
> Me at Debian: http://wiki.debian.org/SandroTosi
>
-- 
Dr. Mauro J. Cavalcanti
Ecoinformatics Studio
P.O. Box 46521, CEP 20551-970
Rio de Janeiro, RJ, BRASIL
E-mail: mau...@gm...
Web: http://studio.infobio.net
Linux Registered User #473524 * Ubuntu User #22717
"Life is complex. It consists of real and imaginary parts."
From: Jouni K. S. <jk...@ik...> - 2009年01月13日 07:15:48
"T J" <tj...@gm...> writes:
> So it looks as if the plot title, for example, is getting Nimbus
> rather than CM. 
The usetex code looks at the font settings in your rc file and chooses
the first matching font that it knows how to use in TeX. Your settings
(probably inherited from the defaults) specify choosing a font in the
sans serif family:
> 'font.family': 'sans-serif',
and of those, Helvetica happens to be the first one in this list that it
knows about:
> 'font.sans-serif': ['Bitstream Vera Sans',
[...]
> 'Helvetica',
You see Nimbus Sans in the output because that's a free Helvetica
look-alike included by your TeX distribution.
> What is the 'proper' way to get all the fonts to match my document?
Specify Computer Modern fonts in your rc file:
font.sans-serif: Computer Modern Sans Serif
font.serif: Computer Modern Roman
font.monospace: Computer Modern Typewriter
-- 
Jouni K. Seppänen
http://www.iki.fi/jks
From: T J <tj...@gm...> - 2009年01月13日 06:03:07
Hi, my matplotlibrc file is:
backend : GTKAgg
text.usetex	: True
text.latex.preview : True
ps.usedistiller	: xpdf
However, when I create images, regular text is not in the CM font.
When checking the fonts in a pdf viewer, I get:
CM12, Type 1, Embedded
NimbusSanL-Regu, Type 1, Embedded
So it looks as if the plot title, for example, is getting Nimbus
rather than CM. What is the 'proper' way to get all the fonts to
match my document? Using:
title(r'$\textrm{title}$')
results in a different font (but still not what I was expecting):
CenturySchL-Roma Below is the output of rcParams.
Thanks.
{'agg.path.chunksize': 0,
 'axes.axisbelow': False,
 'axes.edgecolor': 'k',
 'axes.facecolor': 'w',
 'axes.formatter.limits': [-7, 7],
 'axes.grid': False,
 'axes.hold': True,
 'axes.labelcolor': 'k',
 'axes.labelsize': 'medium',
 'axes.linewidth': 1.0,
 'axes.titlesize': 'large',
 'axes.unicode_minus': True,
 'backend': 'GTKAgg',
 'backend_fallback': True,
 'cairo.format': 'png',
 'contour.negative_linestyle': 'dashed',
 'datapath': '/usr/local/lib/python2.5/site-packages/matplotlib/mpl-data',
 'docstring.hardcopy': False,
 'figure.autolayout': False,
 'figure.dpi': 80,
 'figure.edgecolor': 'w',
 'figure.facecolor': '0.75',
 'figure.figsize': [8.0, 6.0],
 'figure.subplot.bottom': 0.10000000000000001,
 'figure.subplot.hspace': 0.20000000000000001,
 'figure.subplot.left': 0.125,
 'figure.subplot.right': 0.90000000000000002,
 'figure.subplot.top': 0.90000000000000002,
 'figure.subplot.wspace': 0.20000000000000001,
 'font.cursive': ['Apple Chancery',
 'Textile',
 'Zapf Chancery',
 'Sand',
 'cursive'],
 'font.family': 'sans-serif',
 'font.fantasy': ['Comic Sans MS',
 'Chicago',
 'Charcoal',
 'ImpactWestern',
 'fantasy'],
 'font.monospace': ['Bitstream Vera Sans Mono',
 'DejaVu Sans Mono',
 'Andale Mono',
 'Nimbus Mono L',
 'Courier New',
 'Courier',
 'Fixed',
 'Terminal',
 'monospace'],
 'font.sans-serif': ['Bitstream Vera Sans',
 'DejaVu Sans',
 'Lucida Grande',
 'Verdana',
 'Geneva',
 'Lucid',
 'Arial',
 'Helvetica',
 'Avant Garde',
 'sans-serif'],
 'font.serif': ['Bitstream Vera Serif',
 'DejaVu Serif',
 'New Century Schoolbook',
 'Century Schoolbook L',
 'Utopia',
 'ITC Bookman',
 'Bookman',
 'Nimbus Roman No9 L',
 'Times New Roman',
 'Times',
 'Palatino',
 'Charter',
 'serif'],
 'font.size': 12.0,
 'font.stretch': 'normal',
 'font.style': 'normal',
 'font.variant': 'normal',
 'font.weight': 'normal',
 'grid.color': 'k',
 'grid.linestyle': ':',
 'grid.linewidth': 0.5,
 'image.aspect': 'equal',
 'image.cmap': 'jet',
 'image.interpolation': 'bilinear',
 'image.lut': 256,
 'image.origin': 'upper',
 'image.resample': False,
 'interactive': True,
 'legend.borderaxespad': 0.5,
 'legend.borderpad': 0.40000000000000002,
 'legend.columnspacing': 2.0,
 'legend.fancybox': False,
 'legend.fontsize': 'large',
 'legend.handlelength': 2.0,
 'legend.handletextpad': 0.80000000000000004,
 'legend.isaxes': True,
 'legend.labelspacing': 0.5,
 'legend.loc': 'upper right',
 'legend.markerscale': 1.0,
 'legend.numpoints': 2,
 'legend.shadow': False,
 'lines.antialiased': True,
 'lines.color': 'b',
 'lines.dash_capstyle': 'butt',
 'lines.dash_joinstyle': 'miter',
 'lines.linestyle': '-',
 'lines.linewidth': 1.0,
 'lines.marker': 'None',
 'lines.markeredgewidth': 0.5,
 'lines.markersize': 6,
 'lines.solid_capstyle': 'projecting',
 'lines.solid_joinstyle': 'miter',
 'maskedarray': 'obsolete',
 'mathtext.bf': 'serif:bold',
 'mathtext.cal': 'cursive',
 'mathtext.default': 'it',
 'mathtext.fallback_to_cm': True,
 'mathtext.fontset': 'cm',
 'mathtext.it': 'serif:italic',
 'mathtext.rm': 'serif',
 'mathtext.sf': 'sans\\-serif',
 'mathtext.tt': 'monospace',
 'numerix': 'numpy',
 'patch.antialiased': True,
 'patch.edgecolor': 'k',
 'patch.facecolor': 'b',
 'patch.linewidth': 1.0,
 'path.simplify': True,
 'pdf.compression': 6,
 'pdf.fonttype': 3,
 'pdf.inheritcolor': False,
 'pdf.use14corefonts': False,
 'plugins.directory': '.matplotlib_plugins',
 'polaraxes.grid': True,
 'ps.distiller.res': 6000,
 'ps.fonttype': 3,
 'ps.papersize': 'letter',
 'ps.useafm': False,
 'ps.usedistiller': 'xpdf',
 'savefig.dpi': 100,
 'savefig.edgecolor': 'w',
 'savefig.facecolor': 'w',
 'savefig.orientation': 'portrait',
 'svg.embed_char_paths': True,
 'svg.image_inline': True,
 'svg.image_noscale': False,
 'text.color': 'k',
 'text.dvipnghack': None,
 'text.fontangle': 'normal',
 'text.fontsize': 'medium',
 'text.fontstyle': 'normal',
 'text.fontvariant': 'normal',
 'text.fontweight': 'normal',
 'text.latex.preamble': [''],
 'text.latex.preview': True,
 'text.latex.unicode': False,
 'text.usetex': True,
 'timezone': 'UTC',
 'tk.pythoninspect': False,
 'tk.window_focus': False,
 'toolbar': 'toolbar2',
 'units': False,
 'verbose.fileo': 'sys.stdout',
 'verbose.level': 'silent',
 'xtick.color': 'k',
 'xtick.direction': 'in',
 'xtick.labelsize': 'medium',
 'xtick.major.pad': 4,
 'xtick.major.size': 4,
 'xtick.minor.pad': 4,
 'xtick.minor.size': 2,
 'ytick.color': 'k',
 'ytick.direction': 'in',
 'ytick.labelsize': 'medium',
 'ytick.major.pad': 4,
 'ytick.major.size': 4,
 'ytick.minor.pad': 4,
 'ytick.minor.size': 2}
From: Eric F. <ef...@ha...> - 2009年01月13日 02:56:02
Simson Garfinkel wrote:
> 
> On Jan 12, 2009, at 11:53 AM, Eric Firing wrote:
> 
>> Simson Garfinkel wrote:
>>> Hi. It's me again, asking about dates again.
>>> is there any easy way to a collection using dates on the X axes? 
>>> I've taken the collection example from the website and adopted it so 
>>> that there is a use_dates flag. Set it to False and spirals demo 
>>> appears. Set it to True and I get this error:
>>
>> Yes, it looks like a bug in the handling of units in the Collection 
>> base class; unit conversion is done at drawing time, but needs either 
>> to be done earlier, or to be done independently in the get_datalim 
>> method.
>>
>> Maybe one of the units-support experts will pick this up and fix it. 
>> I can't do more now.
> 
> Hi, Eric.
> 
> Ah. Just my luck. I always push this stuff in new and unexpected ways.
> 
> Here's what I'm trying to do --- I want to plot a graph of circles where 
> the size of the circle and color are determined by the data, where the X 
> axis is year/month/day, and the Y axis is just day. (So a lot of "1" 
> values would be a lot of slightly diagonal lines.)
> 
> Any idea how to do this within the current matplotlib, or should I just 
> hack it by hand?
Simson,
The scatter function or Axes method is designed for exactly this, but 
units support was broken in two places. I have fixed it in 6781 on the 
98.5 maintenance branch, merged to the trunk in 6782. So, please update 
to one of these and try scatter(). (Watch out for the odd definition of 
the "s" kwarg for size: area in points squared.)
Eric
> 
> Thanks.
> 

Showing 22 results of 22

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