[Matplotlib-users] Contour/Contourf dynamically with slider
Hi all, I want to make a contout plot with a slider element. But I am not sure if it is possible at all and if it is possible how. The code is a mixture of two examples I found in the web. One part is the slider example of matplotlib from pylab import * N = 50 x = linspace(.0, 1.0, N) y = linspace(.0, 1.0, N) X, Y = meshgrid(x, y) Z = sin(X+16) - 2*cos(Y*5.2) c = contourf(X, Y, Z,20) colorbar() # Copied from the slider example ... not sure about the syntax axfreq = axes([0.25, 0.1, 0.65, 0.03]) sfreq = Slider(axfreq, 'Amp', 0.1, 10.0, valinit=1) def update(val): global sfreq freq = sfreq.val Z = sin(freq*X+16) - 2*cos(Y*5.2) c.set_data(Z) # Is something like that possible draw() sfreq.on_changed(update) show() I tried different stuff, but could not solve the problem. Perhaps anybody has an idea to help me. Thank you! Best regards Stefan -- View this message in context: http://old.nabble.com/Contour-Contourf-dynamically-with-slider-tp30698071p30698071.html Sent from the matplotlib - users mailing list archive at Nabble.com. -- Protect Your Site and Customers from Malware Attacks Learn about various malware tactics and how to avoid them. Understand malware threats, the impact they can have on your business, and how you can protect your company and customers by using code signing. http://p.sf.net/sfu/oracle-sfdevnl ___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
[Matplotlib-users] colorbar: format labels with mathtext
Hi Everyone, I would like to format the labels of a colorbar with mathtext. I have tried a lot with all the cax.formatter.___ options but unfortunately I was not able to get it working. I am plotting some Data with col = ax.pcolorfast( ... ) after this I create a colorbar with cax = fig.colorbar(col) Then I would like to change the formatter and the powerlimits with cax.formatter.format = '$%1.2f$' cax.formatter.set_powerlimits( (-4,4) ) but this does not work for me. Could you pleas help me to set the powerlimits and to format the labels of a colorbar with mathtext. Regards, Stefan -- Protect Your Site and Customers from Malware Attacks Learn about various malware tactics and how to avoid them. Understand malware threats, the impact they can have on your business, and how you can protect your company and customers by using code signing. http://p.sf.net/sfu/oracle-sfdevnl ___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
Re: [Matplotlib-users] [matplotlib-devel] [basemap] hammer projection and bug ?
On 1/18/11 3:33 AM, Nathanaël Schaeffer wrote: Dear matplotlib developpers, I use matplotlib for several years and I'm very satisfied with the it. I started using the basemap package a few days ago, and I noticed something that looks like a bug : With the Mollweide projection (and others too), when specifying rsphere=1.0, the coastlines is not drawn in the left part of the plot. With rsphere=2.0 the hidden part is smaller, and with rsphere=10.0 it is not visible. I'm using matplotlib 1.0.0 and basemap 1.0 To reproduce the bug : m = Basemap(projection='moll',lon_0=180,rsphere=1.0) m.drawcoastlines(linewidth=0.5, color='grey') # draw discrete coastlines m.drawmapboundary()# draw a line around the map region show() Nathanaël: Your test script works fine for me (no coastlines are missing). What version of the geos library did you link against? -Jeff -- Protect Your Site and Customers from Malware Attacks Learn about various malware tactics and how to avoid them. Understand malware threats, the impact they can have on your business, and how you can protect your company and customers by using code signing. http://p.sf.net/sfu/oracle-sfdevnl ___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
Re: [Matplotlib-users] X11 Window information for plots
You're right -- matplotlib doesn't set any of these attributes. Fixing this problem would involve adding a few lines of code to set them in each GUI backend (since each GUI toolkit, gtk, qt, tk etc. presumably handles them differently). Is this something you'd be interested in providing a patch for? Mike On 01/15/2011 03:06 PM, todd rme wrote: On X11 systems, windows generally provide information about themselves to the system. These include things like the window title, window class, window role, and window type. These allow window managers to properly handle the windows, and in some window managers (like KDE's kwin), lets you set rules for windows of certain types. As best as I can tell, by default matplotlib does not provide most of this information. It provides the window title and the window type, but it doesn't seem to provide the window class or the window role. These two properties, however, are exactly the properties someone would want to use when trying to set up rules for particular windows. This makes it impossible to set window-specific rules for the plots. Is there something in the matplotlib configuration that would let someone set these properties, and if not is there any way matplotlib could set them itself? I'm sorry if this is a common question. -Todd -- Protect Your Site and Customers from Malware Attacks Learn about various malware tactics and how to avoid them. Understand malware threats, the impact they can have on your business, and how you can protect your company and customers by using code signing. http://p.sf.net/sfu/oracle-sfdevnl ___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users -- Protect Your Site and Customers from Malware Attacks Learn about various malware tactics and how to avoid them. Understand malware threats, the impact they can have on your business, and how you can protect your company and customers by using code signing. http://p.sf.net/sfu/oracle-sfdevnl ___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
Re: [Matplotlib-users] [matplotlib-devel] [basemap] hammer projection and bug ?
On 1/18/11 6:43 AM, Nathanaël Schaeffer wrote: If it can help, here is a screenshot of the resulting figure of the previous script : http://www.zimagez.com/zimage/basemapbug.php Interestingly, when hoovering the mouse over the figure the displayed x values start at 0 on the beginning of the coastlines, not on the drawn boudary maps, and ends at 4.83 at the other end. On Tue, Jan 18, 2011 at 2:29 PM, Nathanaël Schaeffer nathanael.schaef...@gmail.com mailto:nathanael.schaef...@gmail.com wrote: 2011/1/18 Jeff Whitaker jsw...@fastmail.fm mailto:jsw...@fastmail.fm On 1/18/11 3:33 AM, Nathanaël Schaeffer wrote: Dear matplotlib developpers, I use matplotlib for several years and I'm very satisfied with the it. I started using the basemap package a few days ago, and I noticed something that looks like a bug : With the Mollweide projection (and others too), when specifying rsphere=1.0, the coastlines is not drawn in the left part of the plot. With rsphere=2.0 the hidden part is smaller, and with rsphere=10.0 it is not visible. I'm using matplotlib 1.0.0 and basemap 1.0 To reproduce the bug : m = Basemap(projection='moll',lon_0=180,rsphere=1.0) m.drawcoastlines(linewidth=0.5, color='grey') # draw discrete coastlines m.drawmapboundary()# draw a line around the map region show() Nathanaël: Your test script works fine for me (no coastlines are missing). What version of the geos library did you link against? geos 3.2.2 Concerning your previous message, sure r=1 is small, but I would have thought that it is a simple scaling, and with double precision floating point numbers, this should not be a problem. In physics, it is common to set unit radius for the sphere. Anyway, this is not a very important bug, as setting a larger value works well. Nathanaël: Can't reproduce it (I'm using geos 3.2.2 as well). Can you try updating from svn and see if the problem persists? You'll get hammer that way too. -Jeff -- Protect Your Site and Customers from Malware Attacks Learn about various malware tactics and how to avoid them. Understand malware threats, the impact they can have on your business, and how you can protect your company and customers by using code signing. http://p.sf.net/sfu/oracle-sfdevnl___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
Re: [Matplotlib-users] yticks on the right and label size
On Tue, Jan 18, 2011 at 2:52 AM, g.plantagen...@runbox.com wrote: Hi, I have a problem with plotting two different quantities on the same plot (overlaying two different axes). I plot two different quantities, with different scales, on two overlapping axes. So, I want the quantity 1 to refer to the y axis on the left (with its ticks and labels), and quantity 2 to refer to the y axis on the right (with its ticks and labels). I choose on which side I want the ticks with ax.yaxis.tick_left(). Anyway, if I want then to change the label size of the right y axis, I can't do that. I included a sample plot. My code is something like this: F = figure() #First quantity AX1 = F.add_axes(rect) AX1.plot(x1,y1) AX1.yaxis.tick_left() #with this I say quantity 1=left y axis AX1.set_yticks(range(2,14,2)) AX1.set_yticklabels(range(2,14,2),size=20) #Second quantity (with different scale) AX2 = F.add_axes(rect,frameon=False) AX2.plot(x2,y2) AX2.yaxis.tick_right() #If I leave this line, I can't change the tick label size, if I remove it, I get ticks on both sides AX2.set_yticks(np.arange(16.8,18.8,0.4)) AX2.set_yticklabels(np.arange(16.8,18.8,0.4),size=20,position=(1.08,0)) Instead of tick_right() try: AX2.yaxis.set_ticks_position('right') Ryan -- Ryan May Graduate Research Assistant School of Meteorology University of Oklahoma -- Protect Your Site and Customers from Malware Attacks Learn about various malware tactics and how to avoid them. Understand malware threats, the impact they can have on your business, and how you can protect your company and customers by using code signing. http://p.sf.net/sfu/oracle-sfdevnl ___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
Re: [Matplotlib-users] yticks on the right and label size
Instead of tick_right() try: AX2.yaxis.set_ticks_position('right') Unfortunately this doesn't solve the problem (if it matters, I run matplotlib version 0.99 from Fedora 13). -- Protect Your Site and Customers from Malware Attacks Learn about various malware tactics and how to avoid them. Understand malware threats, the impact they can have on your business, and how you can protect your company and customers by using code signing. http://p.sf.net/sfu/oracle-sfdevnl ___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
[Matplotlib-users] help! figures closing automatically
Hello, I just upgraded my computer to windows 7. I have everything (python, wxpython, matplotlib, numpy) running now, but there is an annoying problem that when I double click on one of my scripts (simple pylab script) it runs creates a figure and plot then immediately closes... so I don't get to look at my plot. I have WXagg configured as the backend because I use matplotlib in several wxpython applications. But right now I am just using pylabin a single script to make simple plots. If I run the script from IDLE it works ok until I try to close the figure, then it locks up until I kill the IDLE. If I run in pythonwin I get the same problem as the IDLE. I'd like to just click on the script icon to run it, and when I run the script from the IDLE I'd like the figure to close when I kill it. How might I correct these issues? Thanks, Jeff -- Protect Your Site and Customers from Malware Attacks Learn about various malware tactics and how to avoid them. Understand malware threats, the impact they can have on your business, and how you can protect your company and customers by using code signing. http://p.sf.net/sfu/oracle-sfdevnl___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
Re: [Matplotlib-users] X11 Window information for plots
Maybe, I am not that familiar with X11 programming. Do you happen to know which source files I should change? -Todd On Tue, Jan 18, 2011 at 8:39 AM, Michael Droettboom md...@stsci.edu wrote: You're right -- matplotlib doesn't set any of these attributes. Fixing this problem would involve adding a few lines of code to set them in each GUI backend (since each GUI toolkit, gtk, qt, tk etc. presumably handles them differently). Is this something you'd be interested in providing a patch for? Mike On 01/15/2011 03:06 PM, todd rme wrote: On X11 systems, windows generally provide information about themselves to the system. These include things like the window title, window class, window role, and window type. These allow window managers to properly handle the windows, and in some window managers (like KDE's kwin), lets you set rules for windows of certain types. As best as I can tell, by default matplotlib does not provide most of this information. It provides the window title and the window type, but it doesn't seem to provide the window class or the window role. These two properties, however, are exactly the properties someone would want to use when trying to set up rules for particular windows. This makes it impossible to set window-specific rules for the plots. Is there something in the matplotlib configuration that would let someone set these properties, and if not is there any way matplotlib could set them itself? I'm sorry if this is a common question. -Todd -- Protect Your Site and Customers from Malware Attacks Learn about various malware tactics and how to avoid them. Understand malware threats, the impact they can have on your business, and how you can protect your company and customers by using code signing. http://p.sf.net/sfu/oracle-sfdevnl ___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users -- Protect Your Site and Customers from Malware Attacks Learn about various malware tactics and how to avoid them. Understand malware threats, the impact they can have on your business, and how you can protect your company and customers by using code signing. http://p.sf.net/sfu/oracle-sfdevnl ___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users -- Protect Your Site and Customers from Malware Attacks Learn about various malware tactics and how to avoid them. Understand malware threats, the impact they can have on your business, and how you can protect your company and customers by using code signing. http://p.sf.net/sfu/oracle-sfdevnl ___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
Re: [Matplotlib-users] Contour/Contourf dynamically with slider
On 01/17/2011 10:24 PM, sprobst wrote: Hi all, I want to make a contout plot with a slider element. But I am not sure if it is possible at all and if it is possible how. With contouring, you have to simply remake the ContourSet (that is, re-run contour) with any change to the data being contoured. Eric The code is a mixture of two examples I found in the web. One part is the slider example of matplotlib from pylab import * N = 50 x = linspace(.0, 1.0, N) y = linspace(.0, 1.0, N) X, Y = meshgrid(x, y) Z = sin(X+16) - 2*cos(Y*5.2) c = contourf(X, Y, Z,20) colorbar() # Copied from the slider example ... not sure about the syntax axfreq = axes([0.25, 0.1, 0.65, 0.03]) sfreq = Slider(axfreq, 'Amp', 0.1, 10.0, valinit=1) def update(val): global sfreq freq = sfreq.val Z = sin(freq*X+16) - 2*cos(Y*5.2) c.set_data(Z) # Is something like that possible draw() sfreq.on_changed(update) show() I tried different stuff, but could not solve the problem. Perhaps anybody has an idea to help me. Thank you! Best regards Stefan -- Protect Your Site and Customers from Malware Attacks Learn about various malware tactics and how to avoid them. Understand malware threats, the impact they can have on your business, and how you can protect your company and customers by using code signing. http://p.sf.net/sfu/oracle-sfdevnl ___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
Re: [Matplotlib-users] help! figures closing automatically
On Tue, Jan 18, 2011 at 10:56 AM, Jeff Peery jeffpe...@seametrics.comwrote: Hello, I just upgraded my computer to windows 7. I have everything (python, wxpython, matplotlib, numpy) running now, but there is an annoying problem that when I double click on one of my scripts (simple pylab script) it runs creates a figure and plot then immediately closes… so I don’t get to look at my plot. I have WXagg configured as the backend because I use matplotlib in several wxpython applications. But right now I am just using pylabin a single script to make simple plots. If I run the script from IDLE it works ok until I try to close the figure, then it locks up until I kill the IDLE. If I run in pythonwin I get the same problem as the IDLE. I’d like to just click on the script icon to run it, and when I run the script from the IDLE I’d like the figure to close when I kill it. How might I correct these issues? Thanks, Jeff This probably depends on on you are coding the plot generation scripts. Can you attach a script for us to see? Ben Root -- Protect Your Site and Customers from Malware Attacks Learn about various malware tactics and how to avoid them. Understand malware threats, the impact they can have on your business, and how you can protect your company and customers by using code signing. http://p.sf.net/sfu/oracle-sfdevnl___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
Re: [Matplotlib-users] yticks on the right and label size
Instead of tick_right() try: AX2.yaxis.set_ticks_position('right') Unfortunately this doesn't solve the problem (if it matters, I run matplotlib version 0.99 from Fedora 13). -- Protect Your Site and Customers from Malware Attacks Learn about various malware tactics and how to avoid them. Understand malware threats, the impact they can have on your business, and how you can protect your company and customers by using code signing. http://p.sf.net/sfu/oracle-sfdevnl ___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
[Matplotlib-users] what does numRows, numCols in subplot docs mean?
subplot(numRows, numCols, plotNum) On my local disk, the file: file:///usr/share/doc/python-matplotlib-doc/html/api/pyplot_api.html#matplotlib.pyplot.subplot contains: subplot(numRows, numCols, plotNum) where plotNum = 1 is the first plot number and increasing plotNums fill rows first. max(plotNum) == numRows * numCols and then, a little later: New subplots that overlap old will delete the old axes. However, that doc does not explain what a row or column is or what overlap means. Is there some way the figure is partitioned into rows and columns and the subplots appear in these rows and columns. If so, then how is this partition done? Does subplot(1,2,1) appear to the left and at same level as subplot(1,2,2)? What if there's subplot(1,2,1) and subplot(2,1,1). Do they overlap and if so, why? IOW, what's the definition of overlap? TIA. -regards, Larry -- Protect Your Site and Customers from Malware Attacks Learn about various malware tactics and how to avoid them. Understand malware threats, the impact they can have on your business, and how you can protect your company and customers by using code signing. http://p.sf.net/sfu/oracle-sfdevnl ___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
[Matplotlib-users] a question to John Hunter
Hello John As you update legend.py with draggable() function, how can create my draggable legend with old version of matplotlib as if use ax.legend(), it always gives me None so I cann't use Adam Fraser's code Draggable(ax.legend()) class. Regards, Renfan With Alstom, preserve the environment. Is printing this email really necessary ? :.___ CONFIDENTIALITY : This e-mail and any attachments are confidential and may be privileged. If you are not a named recipient, please notify the sender immediately and do not disclose the contents to another person, use it for any purpose or store or copy the information in any medium.-- Protect Your Site and Customers from Malware Attacks Learn about various malware tactics and how to avoid them. Understand malware threats, the impact they can have on your business, and how you can protect your company and customers by using code signing. http://p.sf.net/sfu/oracle-sfdevnl___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
[Matplotlib-users] Scientific tools tutorial at PyCon US, March 9, 2011
Scientific Python Tools not only for Scientists and Engineers = This is the title of my three-hour tutorial at PyCon US: http://us.pycon.org/2011/schedule/sessions/164/ It is a compressed version of my much longer course about: * NumPy * SciPy * matplotlib/IPython * extensions with C and Fortran So if your are new to these tools and go to PyCon, you might consider taking the tutorial. Also, if you know somebody who would likely be interested in this tutorial, please spread the word. Thanks. Mike -- Mike Müller mmuel...@python-academy.de -- Protect Your Site and Customers from Malware Attacks Learn about various malware tactics and how to avoid them. Understand malware threats, the impact they can have on your business, and how you can protect your company and customers by using code signing. http://p.sf.net/sfu/oracle-sfdevnl ___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
[Matplotlib-users] UNIX_import pyplot:_path.so: symbol _ZNSs4_Rep20_S_empty_rep_storageE:referenced symbol not found
Hi everyone,After having compiling and installing Matplotlib 1.0.1 with Python 2.5.5 on a Unix platform sunos5, I ran into the following problem, when trying to import pyplot or pylab.Here is the ouput when using ipython: co29@mx61$ ipython WARNING: Readline services not available on this platform. WARNING: The auto-indent feature requires the readline library Python 2.5.5 (r255:77872, Jan 14 2011, 11:05:26) Type copyright, credits or license for more information. IPython 0.10.1 -- An enhanced Interactive Python. ? - Introduction and overview of IPython's features. %quickref - Quick reference. help - Python's own help system. object? - Details about 'object'. ?object also works, ?? prints more. [~/PYTHON-2.5/bin] |1import numpy [~/PYTHON-2.5/bin] |2import matplotlib.pyplot as plt --- ImportError Traceback (most recent call last) /home/co29/PYTHON-2.5/bin/ipython console in module() /home/co29/PYTHON-2.5/lib/python2.5/site-packages/matplotlib/pyplot.py in module() 21 from matplotlib.cbook import dedent, silent_list, is_string_like, is_numlike 22 from matplotlib import docstring --- 23 from matplotlib.figure import Figure, figaspect 24 from matplotlib.backend_bases import FigureCanvasBase 25 from matplotlib.image import imread as _imread /home/co29/PYTHON-2.5/lib/python2.5/site-packages/matplotlib/figure.py in module() 14 import numpy as np 15 --- 16 import artist 17 from artist import Artist, allow_rasterization 18 from axes import Axes, SubplotBase, subplot_class_factory /home/co29/PYTHON-2.5/lib/python2.5/site-packages/matplotlib/artist.py in module() 4 import matplotlib.cbook as cbook 5 from matplotlib import docstring, rcParams 6 from transforms import Bbox, IdentityTransform, TransformedBbox, TransformedPath 7 from path import Path 8 /home/co29/PYTHON-2.5/lib/python2.5/site-packages/matplotlib/transforms.py in module() 32 import numpy as np 33 from numpy import ma --- 34 from matplotlib._path import affine_transform 35 from numpy.linalg import inv 36 ImportError: ld.so.1: ipython: fatal: relocation error: file /home/co29/PYTHON-2.5/lib/python2.5/site-packages/matplotlib/_ path.so: symbol _ZNSs4_Rep20_S_empty_rep_storageE: referenced symbol not found [~/PYTHON-2.5/bin] |3import pylab --- ImportError Traceback (most recent call last) /home/co29/PYTHON-2.5/bin/ipython console in module() /home/co29/PYTHON-2.5/lib/python2.5/site-packages/pylab.py in module() 1 from matplotlib.pylab import * 2 import matplotlib.pylab 3 __doc__ = matplotlib.pylab.__doc__ /home/co29/PYTHON-2.5/lib/python2.5/site-packages/matplotlib/pylab.py in module() 218 silent_list, iterable, dedent 219 -- 220 from matplotlib import mpl # pulls in most modules 221 222 from matplotlib.dates import date2num, num2date,\ /home/co29/PYTHON-2.5/lib/python2.5/site-packages/matplotlib/mpl.py in module() 2 from matplotlib import axis 3 from matplotlib import axes 4 from matplotlib import cbook 5 from matplotlib import collections 6 from matplotlib import colors /home/co29/PYTHON-2.5/lib/python2.5/site-packages/matplotlib/artist.py in module() 4 import matplotlib.cbook as cbook 5 from matplotlib import docstring, rcParams 6 from transforms import Bbox, IdentityTransform, TransformedBbox, TransformedPath 7 from path import Path 8 /home/co29/PYTHON-2.5/lib/python2.5/site-packages/matplotlib/transforms.py in module() 32 import numpy as np 33 from numpy import ma --- 34 from matplotlib._path import affine_transform 35 from numpy.linalg import inv 36 ImportError: ld.so.1: ipython: fatal: relocation error: file /home/co29/PYTHON-2.5/lib/python2.5/site-packages/matplotlib/_path.so: symbol _ZNSs4_Rep20_S_empty_rep_storageE: referenced symbol not found Could anyone help me to solve this problem? Thanks a lot,Best Regards, Clément-- Protect Your Site and Customers from Malware Attacks Learn about various malware tactics and how to avoid them. Understand malware threats, the impact they can have on your business, and how you can protect your company and customers by using code signing. http://p.sf.net/sfu/oracle-sfdevnl___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
Re: [Matplotlib-users] mac osx 10.6 matplotlib installation error: lipo: can't open input file: /var/tmp//*.out
In article 26f19958-353a-471e-a1ee-db33f1207...@sydney.edu.au, Leslie Burnett leslie.burn...@sydney.edu.au wrote: Pathways leading to the error message: I obtained Matplotlib from the matplotlib home page download link to sourceforge a) mpkg/dmg installation 1.0.1-r0 fails with message can't be installed on this disk. matplotlib requires System Python 2.6 to install The mpkg/dmg installer requires python from python.org, not Apple's built-in python (despite the incorrect error message). The README that is displayed by the installer does explain this, but it is easy to miss. Note that the incorrect error message is a known bug in the software that creates mpkg installers. I suggest you use the binary installer because building from source is rather a lot of work, due to the need to install dependencies. -- Russell -- Protect Your Site and Customers from Malware Attacks Learn about various malware tactics and how to avoid them. Understand malware threats, the impact they can have on your business, and how you can protect your company and customers by using code signing. http://p.sf.net/sfu/oracle-sfdevnl ___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
Re: [Matplotlib-users] what does numRows, numCols in subplot docs mean?
From: Paul Ivanov pivanov...@gmail.com To: Larry Evans cppljev...@suddenlink.net Cc: Bcc: Subject: Re: [Matplotlib-users] what does numRows, numCols in subplot docs mean? Reply-To: In-Reply-To: 4d32e05d.4090...@suddenlink.net X-PGP-Key: http://pirsquared.org/PaulIvanov0F3E28F7.asc Larry Evans, on 2011-01-16 06:11, wrote: subplot(numRows, numCols, plotNum) New subplots that overlap old will delete the old axes. However, that doc does not explain what a row or column is or what overlap means. Is there some way the figure is partitioned into rows and columns and the subplots appear in these rows and columns. If so, then how is this partition done? Does subplot(1,2,1) appear to the left and at same level as subplot(1,2,2)? What if there's subplot(1,2,1) and subplot(2,1,1). Do they overlap and if so, why? IOW, what's the definition of overlap? Hi Larry, Overlap means identical parameters for subplot: In [1]: ax1 = plt.subplot(1,2,1) In [2]: ax2 = plt.subplot(1,2,2) In [3]: ax3 = plt.subplot(1,2,1) # overlap, will delete ax1 In [4]: fig = plt.gcf() In [5]: fig.axes Out[5]: [matplotlib.axes.AxesSubplot object at 0xa1b582c, matplotlib.axes.AxesSubplot object at 0xa33968c] In [6]: ax1 Out[6]: matplotlib.axes.AxesSubplot object at 0xa1b582c In [7]: ax2 Out[7]: matplotlib.axes.AxesSubplot object at 0xa33968c In [8]: ax3 Out[8]: matplotlib.axes.AxesSubplot object at 0xa1b582c In [9]: ax4 = plt.subplot(2,2,1) # also overlaps with ax3 In [10]: ax5 = plt.subplot(2,2,4) # overlaps with ax2 In [12]: fig.axes Out[12]: [matplotlib.axes.AxesSubplot object at 0xa49882c, matplotlib.axes.AxesSubplot object at 0xa5118ac] The last parameter (plotNum) for subplot determines which row and column you want based on something like the formula: row = plotNum // numCols column = plotNum % numCols Hope that helps, -- Paul Ivanov 314 address only used for lists, off-list direct email at: http://pirsquared.org | GPG/PGP key id: 0x0F3E28F7 signature.asc Description: Digital signature -- Protect Your Site and Customers from Malware Attacks Learn about various malware tactics and how to avoid them. Understand malware threats, the impact they can have on your business, and how you can protect your company and customers by using code signing. http://p.sf.net/sfu/oracle-sfdevnl___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
Re: [Matplotlib-users] UNIX_import pyplot:_path.so: symbol _ZNSs4_Rep20_S_empty_rep_storageE:referenced symbol not found
Clément PORNET, on 2011-01-18 18:39, wrote: Hi everyone,After having compiling and installing Matplotlib 1.0.1 with Python 2.5.5 on a Unix platform sunos5, I ran into the following problem, when trying to import pyplot or pylab.Here is the ouput when using ipython: ImportError: ld.so.1: ipython: fatal: relocation error: file /home/co29/PYTHON-2.5/lib/python2.5/site-packages/matplotlib/_path.so: symbol _ZNSs4_Rep20_S_empty_rep_storageE: referenced symbol not found Clément, this is likely due to a misbuilt matplotlib - have you update numpy since you last built matplotlib? Can you try deleting ../site-packages/matplotlib, and the build/ directory for your sources of mpl1.0.1 and reinstall? Please report back either way so we get a handle on this. best, -- Paul Ivanov 314 address only used for lists, off-list direct email at: http://pirsquared.org | GPG/PGP key id: 0x0F3E28F7 signature.asc Description: Digital signature -- Protect Your Site and Customers from Malware Attacks Learn about various malware tactics and how to avoid them. Understand malware threats, the impact they can have on your business, and how you can protect your company and customers by using code signing. http://p.sf.net/sfu/oracle-sfdevnl___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
Re: [Matplotlib-users] X11 Window information for plots
I think I've found it. But now I need to know what the values should be. I assume the application name should be matplotlib (no quotes, with no capitalization). What about the window role? I am think either figure or plot would be good, probably the former (once again without quotes and with no capitalization). Is that reasonable? It is easy to change later, although the change should be consistent across all backends. The other issue is whether I should use the same window role for all backends, or separate roles for each backend (such as qt4 figure). Does anyone have an opinion on this? -Todd On Tue, Jan 18, 2011 at 12:54 PM, todd rme toddrme2...@gmail.com wrote: Maybe, I am not that familiar with X11 programming. Do you happen to know which source files I should change? -Todd On Tue, Jan 18, 2011 at 8:39 AM, Michael Droettboom md...@stsci.edu wrote: You're right -- matplotlib doesn't set any of these attributes. Fixing this problem would involve adding a few lines of code to set them in each GUI backend (since each GUI toolkit, gtk, qt, tk etc. presumably handles them differently). Is this something you'd be interested in providing a patch for? Mike On 01/15/2011 03:06 PM, todd rme wrote: On X11 systems, windows generally provide information about themselves to the system. These include things like the window title, window class, window role, and window type. These allow window managers to properly handle the windows, and in some window managers (like KDE's kwin), lets you set rules for windows of certain types. As best as I can tell, by default matplotlib does not provide most of this information. It provides the window title and the window type, but it doesn't seem to provide the window class or the window role. These two properties, however, are exactly the properties someone would want to use when trying to set up rules for particular windows. This makes it impossible to set window-specific rules for the plots. Is there something in the matplotlib configuration that would let someone set these properties, and if not is there any way matplotlib could set them itself? I'm sorry if this is a common question. -Todd -- Protect Your Site and Customers from Malware Attacks Learn about various malware tactics and how to avoid them. Understand malware threats, the impact they can have on your business, and how you can protect your company and customers by using code signing. http://p.sf.net/sfu/oracle-sfdevnl ___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users -- Protect Your Site and Customers from Malware Attacks Learn about various malware tactics and how to avoid them. Understand malware threats, the impact they can have on your business, and how you can protect your company and customers by using code signing. http://p.sf.net/sfu/oracle-sfdevnl ___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users -- Protect Your Site and Customers from Malware Attacks Learn about various malware tactics and how to avoid them. Understand malware threats, the impact they can have on your business, and how you can protect your company and customers by using code signing. http://p.sf.net/sfu/oracle-sfdevnl ___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
Re: [Matplotlib-users] X11 Window information for plots
On Tuesday, January 18, 2011, todd rme toddrme2...@gmail.com wrote: I think I've found it. But now I need to know what the values should be. I assume the application name should be matplotlib (no quotes, with no capitalization). What about the window role? I am think either figure or plot would be good, probably the former (once again without quotes and with no capitalization). Is that reasonable? It is easy to change later, although the change should be consistent across all backends. The other issue is whether I should use the same window role for all backends, or separate roles for each backend (such as qt4 figure). Does anyone have an opinion on this? -Todd My guess is that they should all have the same name. Any given run of matplotlib can only use one backend at a time. I don't see a value in distinguishing the source of the figures. Ben Root On Tue, Jan 18, 2011 at 12:54 PM, todd rme toddrme2...@gmail.com wrote: Maybe, I am not that familiar with X11 programming. Do you happen to know which source files I should change? -Todd On Tue, Jan 18, 2011 at 8:39 AM, Michael Droettboom md...@stsci.edu wrote: You're right -- matplotlib doesn't set any of these attributes. Fixing this problem would involve adding a few lines of code to set them in each GUI backend (since each GUI toolkit, gtk, qt, tk etc. presumably handles them differently). Is this something you'd be interested in providing a patch for? Mike On 01/15/2011 03:06 PM, todd rme wrote: On X11 systems, windows generally provide information about themselves to the system. These include things like the window title, window class, window role, and window type. These allow window managers to properly handle the windows, and in some window managers (like KDE's kwin), lets you set rules for windows of certain types. As best as I can tell, by default matplotlib does not provide most of this information. It provides the window title and the window type, but it doesn't seem to provide the window class or the window role. These two properties, however, are exactly the properties someone would want to use when trying to set up rules for particular windows. This makes it impossible to set window-specific rules for the plots. Is there something in the matplotlib configuration that would let someone set these properties, and if not is there any way matplotlib could set them itself? I'm sorry if this is a common question. -Todd -- Protect Your Site and Customers from Malware Attacks Learn about various malware tactics and how to avoid them. Understand malware threats, the impact they can have on your business, and how you can protect your company and customers by using code signing. http://p.sf.net/sfu/oracle-sfdevnl ___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users -- Protect Your Site and Customers from Malware Attacks Learn about various malware tactics and how to avoid them. Understand malware threats, the impact they can have on your business, and how you can protect your company and customers by using code signing. http://p.sf.net/sfu/oracle-sfdevnl ___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users -- Protect Your Site and Customers from Malware Attacks Learn about various malware tactics and how to avoid them. Understand malware threats, the impact they can have on your business, and how you can protect your company and customers by using code signing. http://p.sf.net/sfu/oracle-sfdevnl ___ Matplotlib-users mailing list -- Protect Your Site and Customers from Malware Attacks Learn about various malware tactics and how to avoid them. Understand malware threats, the impact they can have on your business, and how you can protect your company and customers by using code signing. http://p.sf.net/sfu/oracle-sfdevnl ___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users
Re: [Matplotlib-users] X11 Window information for plots
On Tue, Jan 18, 2011 at 8:58 PM, Benjamin Root ben.r...@ou.edu wrote: On Tuesday, January 18, 2011, todd rme toddrme2...@gmail.com wrote: I think I've found it. But now I need to know what the values should be. I assume the application name should be matplotlib (no quotes, with no capitalization). What about the window role? I am think either figure or plot would be good, probably the former (once again without quotes and with no capitalization). Is that reasonable? It is easy to change later, although the change should be consistent across all backends. The other issue is whether I should use the same window role for all backends, or separate roles for each backend (such as qt4 figure). Does anyone have an opinion on this? -Todd My guess is that they should all have the same name. Any given run of matplotlib can only use one backend at a time. I don't see a value in distinguishing the source of the figures. Ben Root That is what I thought as well. There are three properties to deal with. First the window class. This contains two strings. One is simply the application name. The other, however, is a class. I can't find a good explanation of what this is supposed to be. For Firefox, this is Navigator for the browser and Places for the bookmarks manager. For libreoffice writer, it is VCLSalFrame.DocumentWindow. The third is the window role. For the firefox browser, this is browser. For the bookmark manager, it is organizer. So as best as I can tell, the role is a general description of the sort of application it is, such as a web browser. For matplotlib, I think this should probably be plot or graph or something along those lines. The class, on the other hand, seems to be an application-specific description of what the role is within the application. I think this should probably be figure. Does that sound reasonable? -Todd -- Protect Your Site and Customers from Malware Attacks Learn about various malware tactics and how to avoid them. Understand malware threats, the impact they can have on your business, and how you can protect your company and customers by using code signing. http://p.sf.net/sfu/oracle-sfdevnl ___ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users