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
|
2
(2) |
3
(16) |
4
(22) |
5
(7) |
6
|
7
(9) |
8
(2) |
9
|
10
(7) |
11
(15) |
12
(7) |
13
(4) |
14
(7) |
15
(3) |
16
(6) |
17
(20) |
18
(18) |
19
(15) |
20
(27) |
21
(14) |
22
|
23
(1) |
24
(18) |
25
(22) |
26
(36) |
27
(17) |
28
(6) |
29
(2) |
30
(3) |
31
(6) |
|
|
|
|
|
This is probably the docstring problem mentioned at the bottom of <http://www.py2exe.org/index.cgi/MatPlotLib>. -- Christoph On 5/17/2010 4:07 PM, New2Python wrote: > > Hi All, > > I hope someone can help, I have run into a few problems when trying to > execute an exe file created when I use py2exe with matplotlib. > I have python2.5, matplotlib v0.99.1 and py2exe from GUI2Exe v0.5.0 > optimisation is python -OO > the files compile correctly however when I execute the exe I get an error as > shown below > this is an extract > > File "matplotlib\mlab.pyo", line 380, in<module> > TypeError: unsupported operand type(s) for %: 'NoneType' and 'dict' > > the traceback points to this line of my code > > from matplotlib.backends.backend_wxagg import NavigationToolbar2WxAgg > > does anyone know how to solve this, i have seen references made to numpy but > not matplotlib > > Regards > > Marco >
Hi All, I hope someone can help, I have run into a few problems when trying to execute an exe file created when I use py2exe with matplotlib. I have python2.5, matplotlib v0.99.1 and py2exe from GUI2Exe v0.5.0 optimisation is python -OO the files compile correctly however when I execute the exe I get an error as shown below this is an extract File "matplotlib\mlab.pyo", line 380, in <module> TypeError: unsupported operand type(s) for %: 'NoneType' and 'dict' the traceback points to this line of my code from matplotlib.backends.backend_wxagg import NavigationToolbar2WxAgg does anyone know how to solve this, i have seen references made to numpy but not matplotlib Regards Marco -- View this message in context: http://old.nabble.com/py2exe-and-matplotlib-errors-when-executing-exe-tp28589875p28589875.html Sent from the matplotlib - users mailing list archive at Nabble.com.
Hallo, I'm try to use MathTextParser output for cairo in my wxpython gui. Works well under ubunutu linux (maybe dublicated font) but fails under windows (screenshot: http://www.ubuntu-pics.de/bild/62985/auswahl_017_RC86gk.png ). How to tell cairo to use the font file from mpl-data? Here some code: from matplotlib.mathtext import MathTextParser from matplotlib.font_manager import ttfFontProperty import wx import wx.lib.wxcairo import cairo #... MPC = MathTextParser("Cairo") dc = wx.BufferedPaintDC(self) ctx = wx.lib.wxcairo.ContextFromDC(dc) #... width, height, descent, glyphs, rects = self.mathtext_parser.parse(r"$a_0+a_1\xi+a_2\xi^2+a_3\xi^3$",dpi,prop) #... for font, fontsize, s, ox, oy in glyphs: #... fontProp = ttfFontProperty(font) #... ctx.select_font_face (fontProp.name, self.fontangles [fontProp.style], self.fontweights[fontProp.weight]) #... ctx.show_text(s.encode("utf-8")) #... #... greetz Frank
On 05/17/2010 06:32 AM, Reckoner wrote: > Hi, > > Using the following > > >>> pcolor(x,y,z,shading='interp') > > is it possible to change the interpolation method used? I noticed that > there are set_interpolation methods for images created using > > In [83]: h = imshow( z) > > In [84]: h.set_interpolation? > Type: instancemethod > Base Class: <type 'instancemethod'> > String Form: <bound method AxesImage.set_interpolation of > <matplotlib.image.AxesImage object at 0x047B27D0>> > Namespace: Interactive > File: c:\python26\lib\site-packages\matplotlib\image.py > Definition: h.set_interpolation(self, s) > Docstring: > Set the interpolation method the image uses when resizing. > > ACCEPTS: ['nearest' | 'bilinear' | 'bicubic' | 'spline16' | > 'spline36' | 'hanning' | 'hamming' | 'hermite' | 'kaiser' | > 'quadric' | 'catrom' | 'gaussian' | 'bessel' | 'mitchell' | > 'sinc' | 'lanczos' | ] > > are these available for pcolor? No. Pcolor simply fills quadrilaterals. There is a NonUniformImage class that accepts image interpolation options. I don't think anyone has ever gotten around to giving it a nice interface via an Axes method or pyplot function, but there is an example of its use: http://matplotlib.sourceforge.net/examples/pylab_examples/image_nonuniform.html In the svn version of mpl there is also a gouraud shading option to pcolormesh, which provides interpolation on non-rectangular grids. Eric
On 5/17/2010 11:31 AM, Sandy Ydnas wrote: > it gets stuck in all tested by me IDE inclusing Komodo,pythonxy http://matplotlib.sourceforge.net/faq/howto_faq.html#use-show hth, Alan Isaac
Hi, > Is there any API to draw the lines between the labels? > I guess its not possible with this tool. You could use the ticks' properties (one of their children is a matplotlib.lines.Line2D instance which you could modify to your wishes). The second possibility is see is you put a box with only two drawn borders around the labels, which I think might lead to problems. So if you want to inspect, what you can do with those ticks you can use pyplot.getp(object_to_inspect) and pyplot.setp(object_to_inspect) aswell as dir(object_to_inspect). I mostly do this by having an open python shell where I create and check out the properties I want to work on and a little script I modify to check out how the changes affect the plot. What I did looked something like this: >>> from matplotlib import pyplot >>> fig = pyplot.figure() >>> p = fig.add_subplot(111) >>> p.yaxis.set_ticks([3,4,5]) [<matplotlib.axis.YTick object at 0xa3b580c>, <matplotlib.axis.YTick object at 0xa6861cc>, <matplotlib.axis.YTick object at 0xa6a858c>] >>> m = p.yaxis.set_ticks([3,4,5]) >>> dir(m[0]) ['__class__', '__d..........., 'get_children', 'get_cli.......] >>> pyplot.getp(m[0]) alpha = 1.0 ... children = [<matplotlib.lines.Line2D object at 0xa3b5fac>, <m... ... >>> m[0].get_children() >>> pyplot.getp(m[0].get_children()[0]) >>> pyplot.setp(m[0].get_children()[0]) and if you don't have the return of creating the ticks ("m" in this case) then you can get then using >>> p.yaxis.get_children() [<matplotlib.text.Text object at 0xaa80a6c>, <matplotlib.axis.YTick object at 0xaa9494c>, <matplotlib.axis.YTick object at 0xaa80a0c>, <matplotlib.axis.YTick object at 0xaab650c>, <matplotlib.axis.YTick object at 0xaab652c>, <matplotlib.axis.YTick object at 0xaab68ec>, <matplotlib.axis.YTick object at 0xaab6cec>] Hope it helps, Malte
Hi, Using the following >>> pcolor(x,y,z,shading='interp') is it possible to change the interpolation method used? I noticed that there are set_interpolation methods for images created using In [83]: h = imshow( z) In [84]: h.set_interpolation? Type: instancemethod Base Class: <type 'instancemethod'> String Form: <bound method AxesImage.set_interpolation of <matplotlib.image.AxesImage object at 0x047B27D0>> Namespace: Interactive File: c:\python26\lib\site-packages\matplotlib\image.py Definition: h.set_interpolation(self, s) Docstring: Set the interpolation method the image uses when resizing. ACCEPTS: ['nearest' | 'bilinear' | 'bicubic' | 'spline16' | 'spline36' | 'hanning' | 'hamming' | 'hermite' | 'kaiser' | 'quadric' | 'catrom' | 'gaussian' | 'bessel' | 'mitchell' | 'sinc' | 'lanczos' | ] are these available for pcolor? Thanks!
Is there any API to draw the lines between the labels? I guess its not possible with this tool. -- View this message in context: http://old.nabble.com/Formatting-X-axis-tp28579609p28585415.html Sent from the matplotlib - users mailing list archive at Nabble.com.
> Wingware is only example that commerciale soft can not solve this problem > never, What does >>> matplotlib.get_backend() report? According to http://www.wingware.com/doc/howtos/matplotlib they are assuming TkAgg. You may also want to read the suggestions at http://matplotlib.sourceforge.net/users/shell.html for advice on how to use matplotlib interactively from the command shell in an IDE. Basically, you need to make sure your "backend" corresponds to the GUI and interactive mode is set to True. See also http://matplotlib.sourceforge.net/users/customizing.html http://matplotlib.sourceforge.net/faq/installing_faq.html#what-is-a-backend JDH
Mike, Wingware is only example that commerciale soft can not solv ethis problem never, it gets stuck in all tested by me IDE inclusing Komodo,pythonxy,... is is general problem if Matplotlib even staertd in book as I mentined previoulsy it is impossible after show() to continue debug in IDE's for > > > example wingware or pythonxy as stated in Beginning Python > > > Visualization - Crafting Visual Transformation Scripts > > > (2009) > > > page 187 > > > > > > Note If you're not using matplotlib interactively in Python, be > > > sure to call the function show() after all graphs have been > > > generated, as it enters a user interface main loop that will stop > > > execution of the rest of your code. The reason behind this > > > behavior is that matplotlib is designed to be embedded in a GUI as > > > well. > > > In Windows, if you're working from interactive Python, you need > > > only issue show() once; close the figures (or figures) to return > > > to the shell. Subsequent plots will be drawn automatically without > > > issuing show(), and you'll be able to plot graphs interactively. > > > but no one IDE uses ipython Sandy Personally, I don't use Wingware, so I don't know any specifics about > using matplotlib in that environment. You could try asking this > question on a Wingware-related mailing list. > > Mike > From: mat...@li... > Subject: Matplotlib-users Digest, Vol 48, Issue 23 > To: mat...@li... > Date: 2010年5月17日 15:06:07 +0000 > > Send Matplotlib-users mailing list submissions to > mat...@li... > > To subscribe or unsubscribe via the World Wide Web, visit > https://lists.sourceforge.net/lists/listinfo/matplotlib-users > or, via email, send a message with subject or body 'help' to > mat...@li... > > You can reach the person managing the list at > mat...@li... > > When replying, please edit your Subject line so it is more specific > than "Re: Contents of Matplotlib-users digest..." > > > Today's Topics: > > 1. Re: imshow memory problem (Michael Droettboom) > 2. FW: Matplotlib-users Digest, Vol 48, Issue 19 (Sandy Ydnas) > 3. align title of subplot with ylabel (hettling) > 4. Re: FW: Matplotlib-users Digest, Vol 48, Issue 19 > (Michael Droettboom) > > > ---------------------------------------------------------------------- > > Message: 1 > Date: 2010年5月17日 10:47:41 -0400 > From: Michael Droettboom <md...@st...> > Subject: Re: [Matplotlib-users] imshow memory problem > To: Tom?? Farag? <sen...@em...> > Cc: mat...@li... > Message-ID: <4BF...@st...> > Content-Type: text/plain; charset=windows-1252; format=flowed > > On Linux, I only see about an extra 24kb being used when the canvas is > added to a window vs. not adding it (i.e. commenting out the > window.add(canvas) line). > > In general, here's the memory usage to be expected from imshow (if it's > a floating-point, not-rgb(a) array as you have here): > > The original data: 4-bytes-per-pixel for float32 or 8-bytes-per-pixel > for float64 (in your example the array is float64). > Intermediate float data: *if* the original is not float64, then an > intermediate float64 is created (not the case here) > The colorized data: 4-bytes-per-pixel at original array size > The sized data: 4-bytes-per-pixel at the scaled figure size > > I hope I'm not forgetting anything, but the point is that to support > high-speed rendering of plots, the memory usage is much greater than the > data itself. If your data is truly large, the usual technique is to > decimate or downsample it before passing it to matplotlib, as you're not > going to see more data points than pixels on your display anyway. > > Mike > > Tom?? Farag? wrote: > > Hello, > > I am writing a GUI using GTK+ library. I have a question about axes class imshow method memory consumtion. If I pass the imshow an array, the resulting memory consuption is approximatelly 46 times greater than the array size. If I do not add the canvas to a window (in a code below), the memory consuption is "only" 8 times greater. Any tips on how to reduce the memory consuption would be very appreciated and any explanation of how much memmory imshow allocates too. Configuration and script are below. > > > > os: Windowx XP > > matplotlib version: 0.99.1 > > downloaded from: sourceforge.net > > > > script: > > from matplotlib.figure import Figure > > from matplotlib.backends.backend_gtkagg import FigureCanvasGTKAgg > > from pylab import rand > > import gtk > > > > window = gtk.Window() > > window.connect("destroy", gtk.main_quit) > > > > figure = Figure(figsize=(8,6), dpi=72) > > canvas = FigureCanvasGTKAgg(figure) > > axes = figure.add_subplot(111) > > > > window.add(canvas) > > > > axes.imshow(rand(1024,1024)) > > canvas.draw() > > window.show_all() > > > > gtk.main() > > > > verbose-helpful output: > > $HOME=C:\Documents and Settings\Sensej > > CONFIGDIR=C:\Documents and Settings\Sensej\.matplotlib > > matplotlib data path C:\Python26\lib\site-packages\matplotlib\mpl-data > > loaded rc file C:\Python26\lib\site-packages\matplotlib\mpl-data\matplotlibrc > > matplotlib version 0.99.1 > > verbose.level helpful > > interactive is False > > units is False > > platform is win32 > > Using fontManager instance from C:\Documents and Settings\Sensej\.matplotlib\fontList.cache > > backend GTKAgg version 2.12.1 > > findfont: Matching :family=sans-serif:style=normal:variant=normal:weight=normal:stretch=normal:size=medium to Bitstream Vera Sans (C:\Python26\lib\site-packages\matplotlib\mpl-data\fonts\ttf\Vera.ttf) with score of 0.000000 > > > > Thank you, > > Tomas. > > > > ------------------------------------------------------------------------------ > > > > _______________________________________________ > > 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 > > > > > ------------------------------ > > Message: 2 > Date: 2010年5月17日 19:48:50 +0500 > From: Sandy Ydnas <cd...@li...> > Subject: [Matplotlib-users] FW: Matplotlib-users Digest, Vol 48, Issue > 19 > To: <mat...@li...> > Message-ID: <COL...@ph...l> > Content-Type: text/plain; charset="koi8-r" > > > > > > Hello friends, > > > > no body can answer on first obvious question of Matplotlib???!!!!! > > > > > Sandy > > > > From: mat...@li... > > Subject: Matplotlib-users Digest, Vol 48, Issue 19 > > To: mat...@li... > > Date: 2010年5月13日 18:18:52 +0000 > > > > Send Matplotlib-users mailing list submissions to > > mat...@li... > > > > To subscribe or unsubscribe via the World Wide Web, visit > > https://lists.sourceforge.net/lists/listinfo/matplotlib-users > > or, via email, send a message with subject or body 'help' to > > mat...@li... > > > > You can reach the person managing the list at > > mat...@li... > > > > When replying, please edit your Subject line so it is more specific > > than "Re: Contents of Matplotlib-users digest..." > > > > > > Today's Topics: > > > > 1. debugging process gets stuck with matpltlib after show() > > (Sandy Sandy) > > > > > > ---------------------------------------------------------------------- > > > > Message: 1 > > Date: 2010年5月13日 23:18:42 +0500 > > From: Sandy Sandy <cd...@li...> > > Subject: [Matplotlib-users] debugging process gets stuck with > > matpltlib after show() > > To: <mat...@li...> > > Message-ID: <COL...@ph...l> > > Content-Type: text/plain; charset="windows-1252" > > > > > > > > > > Hi all, > > I am new born in Python ( 1 week old) > > > > > > > > Can you pls help to understand the basic concept of > > matpltlib interacting with Python > > > > > > > > the mutter is: > > > > during debugging the debug processes stacks when fig is created > > > > for example, in code > > > > > > > > > > > > import matplotlib.pyplot as plt > > > > from pylab import * > > > > x= 23; > > > > y = 111111; > > > > print(23456) > > > > plt.plot(range(10)) > > > > plot([1,2,3]) > > > > show() > > > > print(11111111) > > > > a=888 > > > > > > > > it is impossible after show() to continue debug in any IDE for example Wingwar > > or pythonxy > > > > as stated in > > > > Beginning Python Visualization - Crafting Visual Transformation Scripts (2009) > > > > page 187 > > > > > > > > Note If you?re not using matplotlib interactively in Python, be sure > > > > to call the function show() after all > > > > graphs have been generated, as it enters a user interface main loop > > > > that will stop execution of the rest of > > > > your code. The reason behind this behavior is that matplotlib is > > > > designed to be embedded in a GUI as well. > > > > In Windows, if you?re working from interactive Python, you need only > > > > issue show() once; close the figures > > > > (or figures) to return to the shell. Subsequent plots will be drawn > > > > automatically without issuing show(), and > > > > you?ll be able to plot graphs interactively. > > > > > > > > > > > > > > > > > > > > I tried the code > > > > > > > > > > > > with threads > > > > as suggested in > > > > http://matplotlib.sourceforge.net/users/shell.html > > > > > > > > code > > taken from people > > from wingware > > > > http://www.wingware.com/doc/howtos/matplotlib > > > > > > > > > > > > from threading import Timer > > > > t = Timer(0, show) > > > > t.start() > > > > > > > > but still debugging process gets > > stuck... > > > > > > import > > matplotlib as mpl > > > > from > > pylab import plot,show,close,ion > > > > x > > = range(10) > > > > plot(x) > > > > 'show()' > > > > from > > threading import Timer > > > > t > > = Timer(0, show) > > > > t.start() > > > > 'ion() > > the same result with or not' > > > > a > > = 1222233 > > > > y > > = [2, 8, 3, 9, 4] > > > > plot(y) > > > > > > > > zz= > > 12346 > > > > print(44444) > > > > > > > > Best Regards > > > > Sandy > > > > > > _________________________________________________________________ > > Hotmail: Trusted email with Microsoft?s powerful SPAM protection. > > https://signup.live.com/signup.aspx?id=60969 > > -------------- next part -------------- > > An HTML attachment was scrubbed... > > > > ------------------------------ > > > > ------------------------------------------------------------------------------ > > > > > > > > ------------------------------ > > > > _______________________________________________ > > Matplotlib-users mailing list > > Mat...@li... > > https://lists.sourceforge.net/lists/listinfo/matplotlib-users > > > > > > End of Matplotlib-users Digest, Vol 48, Issue 19 > > ************************************************ > > _________________________________________________________________ > Hotmail: Powerful Free email with security by Microsoft. > https://signup.live.com/signup.aspx?id=60969 > -------------- next part -------------- > An HTML attachment was scrubbed... > > ------------------------------ > > Message: 3 > Date: 2010年5月17日 17:08:17 +0200 > From: hettling <het...@fe...> > Subject: [Matplotlib-users] align title of subplot with ylabel > To: mat...@li... > Message-ID: <1274108897.30154.11.camel@meerschwein> > Content-Type: text/plain; charset="UTF-8" > > Dear all, > > I'm struggling with the following problem plotting my data: > > I have a figure with two panels next to each other, which I want to > label 'A' and 'B'. I want to left-justify my panel labels, but not to > the box that contains the plot, but to the y-axis label. I played around > with 'text()' and 'title()', but did not find a good solution except for > giving the coordinates manually to 'text()'. This would be very > inconvenient though, because I have many different plots on different > scales. > Here is what I tried: > > ###Code > import scipy > import matplotlib.pyplot as plt > > fig = plt.figure() > ax = fig.add_subplot(121) > plt.plot(scipy.sin(scipy.arange(1,100, 0.001))) > plt.xlabel('xlabel') > plt.ylabel("ylabel") > plt.text(0,1,"A", fontsize=14, transform=ax.transAxes) > > ax = fig.add_subplot(122) > plt.plot(scipy.cos(scipy.arange(1,100, 0.001))) > plt.text(0,1,"B", fontsize=14, transform=ax.transAxes) > plt.xlabel('xlabel') > ###End Code > > So the texts 'A' and 'B' should be a little bit higher and more to the > left. The 'A' I want to align with the y-axis label of the left plot, > the 'B' with the values of the y-axis of the right plot. > > I hope my question is clear, I will appreciate any help! > > Thanks in advance, > > Hannes > > > > > ------------------------------ > > Message: 4 > Date: 2010年5月17日 11:05:58 -0400 > From: Michael Droettboom <md...@st...> > Subject: Re: [Matplotlib-users] FW: Matplotlib-users Digest, Vol 48, > Issue 19 > To: Sandy Ydnas <cd...@li...> > Cc: mat...@li... > Message-ID: <4BF...@st...> > Content-Type: text/plain; charset=KOI8-R; format=flowed > > Personally, I don't use Wingware, so I don't know any specifics about > using matplotlib in that environment. You could try asking this > question on a Wingware-related mailing list. > > Mike > > Sandy Ydnas wrote: > > > > > > Hello friends, > > > > no body can answer on first obvious question of Matplotlib???!!!!! > > > > > > Sandy > > > > > > > From: mat...@li... > > > Subject: Matplotlib-users Digest, Vol 48, Issue 19 > > > To: mat...@li... > > > Date: 2010年5月13日 18:18:52 +0000 > > > > > > Send Matplotlib-users mailing list submissions to > > > mat...@li... > > > > > > To subscribe or unsubscribe via the World Wide Web, visit > > > https://lists.sourceforge.net/lists/listinfo/matplotlib-users > > > or, via email, send a message with subject or body 'help' to > > > mat...@li... > > > > > > You can reach the person managing the list at > > > mat...@li... > > > > > > When replying, please edit your Subject line so it is more specific > > > than "Re: Contents of Matplotlib-users digest..." > > > > > > > > > Today's Topics: > > > > > > 1. debugging process gets stuck with matpltlib after show() > > > (Sandy Sandy) > > > > > > > > > ---------------------------------------------------------------------- > > > > > > Message: 1 > > > Date: 2010年5月13日 23:18:42 +0500 > > > From: Sandy Sandy <cd...@li...> > > > Subject: [Matplotlib-users] debugging process gets stuck with > > > matpltlib after show() > > > To: <mat...@li...> > > > Message-ID: <COL...@ph...l> > > > Content-Type: text/plain; charset="windows-1252" > > > > > > > > > > > > > > > Hi all, > > > I am new born in Python ( 1 week old) > > > > > > > > > > > > Can you pls help to understand the basic concept of > > > matpltlib interacting with Python > > > > > > > > > > > > the mutter is: > > > > > > during debugging the debug processes stacks when fig is created > > > > > > for example, in code > > > > > > > > > > > > > > > > > > import matplotlib.pyplot as plt > > > > > > from pylab import * > > > > > > x= 23; > > > > > > y = 111111; > > > > > > print(23456) > > > > > > plt.plot(range(10)) > > > > > > plot([1,2,3]) > > > > > > show() > > > > > > print(11111111) > > > > > > a=888 > > > > > > > > > > > > it is impossible after show() to continue debug in any IDE for > > example Wingwar > > > or pythonxy > > > > > > as stated in > > > > > > Beginning Python Visualization - Crafting Visual Transformation > > Scripts (2009) > > > > > > page 187 > > > > > > > > > > > > Note If you?re not using matplotlib interactively in Python, be sure > > > > > > to call the function show() after all > > > > > > graphs have been generated, as it enters a user interface main loop > > > > > > that will stop execution of the rest of > > > > > > your code. The reason behind this behavior is that matplotlib is > > > > > > designed to be embedded in a GUI as well. > > > > > > In Windows, if you?re working from interactive Python, you need only > > > > > > issue show() once; close the figures > > > > > > (or figures) to return to the shell. Subsequent plots will be drawn > > > > > > automatically without issuing show(), and > > > > > > you?ll be able to plot graphs interactively. > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > I tried the code > > > > > > > > > > > > > > > > > > with threads > > > > > > as suggested in > > > > > > http://matplotlib.sourceforge.net/users/shell.html > > > > > > > > > > > > code > > > taken from people > > > from wingware > > > > > > http://www.wingware.com/doc/howtos/matplotlib > > > > > > > > > > > > > > > > > > from threading import Timer > > > > > > t = Timer(0, show) > > > > > > t.start() > > > > > > > > > > > > but still debugging process gets > > > stuck... > > > > > > > > > import > > > matplotlib as mpl > > > > > > from > > > pylab import plot,show,close,ion > > > > > > x > > > = range(10) > > > > > > plot(x) > > > > > > 'show()' > > > > > > from > > > threading import Timer > > > > > > t > > > = Timer(0, show) > > > > > > t.start() > > > > > > 'ion() > > > the same result with or not' > > > > > > a > > > = 1222233 > > > > > > y > > > = [2, 8, 3, 9, 4] > > > > > > plot(y) > > > > > > > > > > > > zz= > > > 12346 > > > > > > print(44444) > > > > > > > > > > > > Best Regards > > > > > > Sandy > > > > > > > > > _________________________________________________________________ > > > Hotmail: Trusted email with Microsoft?s powerful SPAM protection. > > > https://signup.live.com/signup.aspx?id=60969 > > > -------------- next part -------------- > > > An HTML attachment was scrubbed... > > > > > > ------------------------------ > > > > > > > > ------------------------------------------------------------------------------ > > > > > > > > > > > > ------------------------------ > > > > > > _______________________________________________ > > > Matplotlib-users mailing list > > > Mat...@li... > > > https://lists.sourceforge.net/lists/listinfo/matplotlib-users > > > > > > > > > End of Matplotlib-users Digest, Vol 48, Issue 19 > > > ************************************************ > > > > ------------------------------------------------------------------------ > > Hotmail: Powerful Free email with security by Microsoft. Get it now. > > <https://signup.live.com/signup.aspx?id=60969> > > ------------------------------------------------------------------------ > > > > ------------------------------------------------------------------------------ > > > > > > ------------------------------------------------------------------------ > > > > _______________________________________________ > > 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 > > > > > ------------------------------ > > ------------------------------------------------------------------------------ > > > > ------------------------------ > > _______________________________________________ > Matplotlib-users mailing list > Mat...@li... > https://lists.sourceforge.net/lists/listinfo/matplotlib-users > > > End of Matplotlib-users Digest, Vol 48, Issue 23 > ************************************************ _________________________________________________________________ Your E-mail and More On-the-Go. Get Windows Live Hotmail Free. https://signup.live.com/signup.aspx?id=60969
Personally, I don't use Wingware, so I don't know any specifics about using matplotlib in that environment. You could try asking this question on a Wingware-related mailing list. Mike Sandy Ydnas wrote: > > > Hello friends, > > no body can answer on first obvious question of Matplotlib???!!!!! > > > Sandy > > > > From: mat...@li... > > Subject: Matplotlib-users Digest, Vol 48, Issue 19 > > To: mat...@li... > > Date: 2010年5月13日 18:18:52 +0000 > > > > Send Matplotlib-users mailing list submissions to > > mat...@li... > > > > To subscribe or unsubscribe via the World Wide Web, visit > > https://lists.sourceforge.net/lists/listinfo/matplotlib-users > > or, via email, send a message with subject or body 'help' to > > mat...@li... > > > > You can reach the person managing the list at > > mat...@li... > > > > When replying, please edit your Subject line so it is more specific > > than "Re: Contents of Matplotlib-users digest..." > > > > > > Today's Topics: > > > > 1. debugging process gets stuck with matpltlib after show() > > (Sandy Sandy) > > > > > > ---------------------------------------------------------------------- > > > > Message: 1 > > Date: 2010年5月13日 23:18:42 +0500 > > From: Sandy Sandy <cd...@li...> > > Subject: [Matplotlib-users] debugging process gets stuck with > > matpltlib after show() > > To: <mat...@li...> > > Message-ID: <COL...@ph...l> > > Content-Type: text/plain; charset="windows-1252" > > > > > > > > > > Hi all, > > I am new born in Python ( 1 week old) > > > > > > > > Can you pls help to understand the basic concept of > > matpltlib interacting with Python > > > > > > > > the mutter is: > > > > during debugging the debug processes stacks when fig is created > > > > for example, in code > > > > > > > > > > > > import matplotlib.pyplot as plt > > > > from pylab import * > > > > x= 23; > > > > y = 111111; > > > > print(23456) > > > > plt.plot(range(10)) > > > > plot([1,2,3]) > > > > show() > > > > print(11111111) > > > > a=888 > > > > > > > > it is impossible after show() to continue debug in any IDE for > example Wingwar > > or pythonxy > > > > as stated in > > > > Beginning Python Visualization - Crafting Visual Transformation > Scripts (2009) > > > > page 187 > > > > > > > > Note If you?re not using matplotlib interactively in Python, be sure > > > > to call the function show() after all > > > > graphs have been generated, as it enters a user interface main loop > > > > that will stop execution of the rest of > > > > your code. The reason behind this behavior is that matplotlib is > > > > designed to be embedded in a GUI as well. > > > > In Windows, if you?re working from interactive Python, you need only > > > > issue show() once; close the figures > > > > (or figures) to return to the shell. Subsequent plots will be drawn > > > > automatically without issuing show(), and > > > > you?ll be able to plot graphs interactively. > > > > > > > > > > > > > > > > > > > > I tried the code > > > > > > > > > > > > with threads > > > > as suggested in > > > > http://matplotlib.sourceforge.net/users/shell.html > > > > > > > > code > > taken from people > > from wingware > > > > http://www.wingware.com/doc/howtos/matplotlib > > > > > > > > > > > > from threading import Timer > > > > t = Timer(0, show) > > > > t.start() > > > > > > > > but still debugging process gets > > stuck... > > > > > > import > > matplotlib as mpl > > > > from > > pylab import plot,show,close,ion > > > > x > > = range(10) > > > > plot(x) > > > > 'show()' > > > > from > > threading import Timer > > > > t > > = Timer(0, show) > > > > t.start() > > > > 'ion() > > the same result with or not' > > > > a > > = 1222233 > > > > y > > = [2, 8, 3, 9, 4] > > > > plot(y) > > > > > > > > zz= > > 12346 > > > > print(44444) > > > > > > > > Best Regards > > > > Sandy > > > > > > _________________________________________________________________ > > Hotmail: Trusted email with Microsoft?s powerful SPAM protection. > > https://signup.live.com/signup.aspx?id=60969 > > -------------- next part -------------- > > An HTML attachment was scrubbed... > > > > ------------------------------ > > > > > ------------------------------------------------------------------------------ > > > > > > > > ------------------------------ > > > > _______________________________________________ > > Matplotlib-users mailing list > > Mat...@li... > > https://lists.sourceforge.net/lists/listinfo/matplotlib-users > > > > > > End of Matplotlib-users Digest, Vol 48, Issue 19 > > ************************************************ > > ------------------------------------------------------------------------ > Hotmail: Powerful Free email with security by Microsoft. Get it now. > <https://signup.live.com/signup.aspx?id=60969> > ------------------------------------------------------------------------ > > ------------------------------------------------------------------------------ > > > ------------------------------------------------------------------------ > > _______________________________________________ > 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
Dear all, I'm struggling with the following problem plotting my data: I have a figure with two panels next to each other, which I want to label 'A' and 'B'. I want to left-justify my panel labels, but not to the box that contains the plot, but to the y-axis label. I played around with 'text()' and 'title()', but did not find a good solution except for giving the coordinates manually to 'text()'. This would be very inconvenient though, because I have many different plots on different scales. Here is what I tried: ###Code import scipy import matplotlib.pyplot as plt fig = plt.figure() ax = fig.add_subplot(121) plt.plot(scipy.sin(scipy.arange(1,100, 0.001))) plt.xlabel('xlabel') plt.ylabel("ylabel") plt.text(0,1,"A", fontsize=14, transform=ax.transAxes) ax = fig.add_subplot(122) plt.plot(scipy.cos(scipy.arange(1,100, 0.001))) plt.text(0,1,"B", fontsize=14, transform=ax.transAxes) plt.xlabel('xlabel') ###End Code So the texts 'A' and 'B' should be a little bit higher and more to the left. The 'A' I want to align with the y-axis label of the left plot, the 'B' with the values of the y-axis of the right plot. I hope my question is clear, I will appreciate any help! Thanks in advance, Hannes
Hello friends, no body can answer on first obvious question of Matplotlib???!!!!! Sandy > From: mat...@li... > Subject: Matplotlib-users Digest, Vol 48, Issue 19 > To: mat...@li... > Date: 2010年5月13日 18:18:52 +0000 > > Send Matplotlib-users mailing list submissions to > mat...@li... > > To subscribe or unsubscribe via the World Wide Web, visit > https://lists.sourceforge.net/lists/listinfo/matplotlib-users > or, via email, send a message with subject or body 'help' to > mat...@li... > > You can reach the person managing the list at > mat...@li... > > When replying, please edit your Subject line so it is more specific > than "Re: Contents of Matplotlib-users digest..." > > > Today's Topics: > > 1. debugging process gets stuck with matpltlib after show() > (Sandy Sandy) > > > ---------------------------------------------------------------------- > > Message: 1 > Date: 2010年5月13日 23:18:42 +0500 > From: Sandy Sandy <cd...@li...> > Subject: [Matplotlib-users] debugging process gets stuck with > matpltlib after show() > To: <mat...@li...> > Message-ID: <COL...@ph...l> > Content-Type: text/plain; charset="windows-1252" > > > > > Hi all, > I am new born in Python ( 1 week old) > > > > Can you pls help to understand the basic concept of > matpltlib interacting with Python > > > > the mutter is: > > during debugging the debug processes stacks when fig is created > > for example, in code > > > > > > import matplotlib.pyplot as plt > > from pylab import * > > x= 23; > > y = 111111; > > print(23456) > > plt.plot(range(10)) > > plot([1,2,3]) > > show() > > print(11111111) > > a=888 > > > > it is impossible after show() to continue debug in any IDE for example Wingwar > or pythonxy > > as stated in > > Beginning Python Visualization - Crafting Visual Transformation Scripts (2009) > > page 187 > > > > Note If you?re not using matplotlib interactively in Python, be sure > > to call the function show() after all > > graphs have been generated, as it enters a user interface main loop > > that will stop execution of the rest of > > your code. The reason behind this behavior is that matplotlib is > > designed to be embedded in a GUI as well. > > In Windows, if you?re working from interactive Python, you need only > > issue show() once; close the figures > > (or figures) to return to the shell. Subsequent plots will be drawn > > automatically without issuing show(), and > > you?ll be able to plot graphs interactively. > > > > > > > > > > I tried the code > > > > > > with threads > > as suggested in > > http://matplotlib.sourceforge.net/users/shell.html > > > > code > taken from people > from wingware > > http://www.wingware.com/doc/howtos/matplotlib > > > > > > from threading import Timer > > t = Timer(0, show) > > t.start() > > > > but still debugging process gets > stuck... > > > import > matplotlib as mpl > > from > pylab import plot,show,close,ion > > x > = range(10) > > plot(x) > > 'show()' > > from > threading import Timer > > t > = Timer(0, show) > > t.start() > > 'ion() > the same result with or not' > > a > = 1222233 > > y > = [2, 8, 3, 9, 4] > > plot(y) > > > > zz= > 12346 > > print(44444) > > > > Best Regards > > Sandy > > > _________________________________________________________________ > Hotmail: Trusted email with Microsoft?s powerful SPAM protection. > https://signup.live.com/signup.aspx?id=60969 > -------------- next part -------------- > An HTML attachment was scrubbed... > > ------------------------------ > > ------------------------------------------------------------------------------ > > > > ------------------------------ > > _______________________________________________ > Matplotlib-users mailing list > Mat...@li... > https://lists.sourceforge.net/lists/listinfo/matplotlib-users > > > End of Matplotlib-users Digest, Vol 48, Issue 19 > ************************************************ _________________________________________________________________ Hotmail: Powerful Free email with security by Microsoft. https://signup.live.com/signup.aspx?id=60969
On Linux, I only see about an extra 24kb being used when the canvas is added to a window vs. not adding it (i.e. commenting out the window.add(canvas) line). In general, here's the memory usage to be expected from imshow (if it's a floating-point, not-rgb(a) array as you have here): The original data: 4-bytes-per-pixel for float32 or 8-bytes-per-pixel for float64 (in your example the array is float64). Intermediate float data: *if* the original is not float64, then an intermediate float64 is created (not the case here) The colorized data: 4-bytes-per-pixel at original array size The sized data: 4-bytes-per-pixel at the scaled figure size I hope I'm not forgetting anything, but the point is that to support high-speed rendering of plots, the memory usage is much greater than the data itself. If your data is truly large, the usual technique is to decimate or downsample it before passing it to matplotlib, as you're not going to see more data points than pixels on your display anyway. Mike Tomáš Faragó wrote: > Hello, > I am writing a GUI using GTK+ library. I have a question about axes class imshow method memory consumtion. If I pass the imshow an array, the resulting memory consuption is approximatelly 46 times greater than the array size. If I do not add the canvas to a window (in a code below), the memory consuption is "only" 8 times greater. Any tips on how to reduce the memory consuption would be very appreciated and any explanation of how much memmory imshow allocates too. Configuration and script are below. > > os: Windowx XP > matplotlib version: 0.99.1 > downloaded from: sourceforge.net > > script: > from matplotlib.figure import Figure > from matplotlib.backends.backend_gtkagg import FigureCanvasGTKAgg > from pylab import rand > import gtk > > window = gtk.Window() > window.connect("destroy", gtk.main_quit) > > figure = Figure(figsize=(8,6), dpi=72) > canvas = FigureCanvasGTKAgg(figure) > axes = figure.add_subplot(111) > > window.add(canvas) > > axes.imshow(rand(1024,1024)) > canvas.draw() > window.show_all() > > gtk.main() > > verbose-helpful output: > $HOME=C:\Documents and Settings\Sensej > CONFIGDIR=C:\Documents and Settings\Sensej\.matplotlib > matplotlib data path C:\Python26\lib\site-packages\matplotlib\mpl-data > loaded rc file C:\Python26\lib\site-packages\matplotlib\mpl-data\matplotlibrc > matplotlib version 0.99.1 > verbose.level helpful > interactive is False > units is False > platform is win32 > Using fontManager instance from C:\Documents and Settings\Sensej\.matplotlib\fontList.cache > backend GTKAgg version 2.12.1 > findfont: Matching :family=sans-serif:style=normal:variant=normal:weight=normal:stretch=normal:size=medium to Bitstream Vera Sans (C:\Python26\lib\site-packages\matplotlib\mpl-data\fonts\ttf\Vera.ttf) with score of 0.000000 > > Thank you, > Tomas. > > ------------------------------------------------------------------------------ > > _______________________________________________ > 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
On Mon, May 17, 2010 at 8:28 AM, Craig Lyndon <c.a...@gm...> wrote: > Hi All, > > Im new to matplotlib, and I love it, but I have a question about the > Licence agreement. > I am wanting to develop a commercial closed source application for my > company using python and matplotlib. > > I have tried reading the Licence agreement, but have trouble understanding it. > Could someone please tell me under what conditions I can use > matplotlib in a closed source application? The license itself is the ultimate reference, but in a nutshell, you are free to use matplotlib in a commercial, closed source application. The only clause that could potentially require action from you is that if you *modify* matplotlib and want to distribute it for others, you need to summarize the changes you made (clause 3). If you end up making a lot of money, remember us on the "donations" page :-) http://sourceforge.net/project/project_donations.php?group_id=80706 JDH
Hi All, Im new to matplotlib, and I love it, but I have a question about the Licence agreement. I am wanting to develop a commercial closed source application for my company using python and matplotlib. I have tried reading the Licence agreement, but have trouble understanding it. Could someone please tell me under what conditions I can use matplotlib in a closed source application? Kind Regards, Craig
On Mon, May 17, 2010 at 6:04 AM, Ralph Kube <ral...@go...> wrote: > Hello folks. > I am trying to teach pylab to use latex to write numbers with an > exponent in the plot legend. > So far my plot labels are formatted with scientific notation, where > I use the format operate: > > import pylab > ra_list,b = data > pylab.plot(ra_list,b, label='Ra = ' + "{0:4.2e}".format(ra_list[i])) > pylab.legend() > pylab.show() > > What I ultimately want is that the exponent shows up as an exponent, > a la LaTeX style in the legend: $\mathrm{Ra} = 10^6$. > > Does anybody know of a way how to do this with pylab? I suggest having a look at the ScalarFormatter classer in ticker.py. The feature you are looking for has already been implemented there. Darren
Hello, I plot views of 3D data without axis. The plotting results usually in plenty of surrounding white space. Is there an easy way to get rid of it (easy meaning without having to keep track of the spacial extension of my 3D data) ? Thanks in advance, Ruben
Hello folks. I am trying to teach pylab to use latex to write numbers with an exponent in the plot legend. So far my plot labels are formatted with scientific notation, where I use the format operate: import pylab ra_list,b = data pylab.plot(ra_list,b, label='Ra = ' + "{0:4.2e}".format(ra_list[i])) pylab.legend() pylab.show() What I ultimately want is that the exponent shows up as an exponent, a la LaTeX style in the legend: $\mathrm{Ra} = 10^6$. Does anybody know of a way how to do this with pylab? Cheers, Ralph
I want to format my graph as in MS-Excel. I don't know what term to use for this. It looks like the X-axis has 2 labels on them. http://old.nabble.com/file/p28579609/omp_parallel.png I have showed it in the image that is generated from Excel. I want to have exactly the same using matplotlib. Can anyone tell me how exactly this can be achieved? Thanks ! Raj. -- View this message in context: http://old.nabble.com/Formatting-X-axis-tp28579609p28579609.html Sent from the matplotlib - users mailing list archive at Nabble.com.