[Matplotlib-users] How to use pcolormesh with two masked arrays

2011-02-01 Thread Jeremy Conlin
I have two arrays and I want to plot the ratio of A/B when A=B or B/A when AB. I can create numpy masked arrays to find the result in these two instances, but I'm having trouble plotting them. Below I have a minimal example. I get a plot, but only from the second time I issue the pcolormesh

Re: [Matplotlib-users] How to use pcolormesh with two masked arrays

2011-02-01 Thread Jeremy Conlin
On Tue, Feb 1, 2011 at 1:11 PM, Benjamin Root ben.r...@ou.edu wrote: On Tue, Feb 1, 2011 at 1:48 PM, Jeremy Conlin jlcon...@gmail.com wrote: On Tue, Feb 1, 2011 at 11:22 AM, Benjamin Root ben.r...@ou.edu wrote: On Tue, Feb 1, 2011 at 11:58 AM, Jeremy Conlin jlcon...@gmail.com wrote

[Matplotlib-users] Custom colormap is inconsistent. What is wrong?

2011-02-01 Thread Jeremy Conlin
I'm trying to create a custom colormap used with pcolormesh, but the results seem inconsistent to me. I want the following colors -3 x = -2 - Black -2 x = -1 - Blue -1 x = 0 - Yellow 0 x = 1 - Green 1 x = inf - Red A minimal example is copied below. I have a 2-D

Re: [Matplotlib-users] Custom colormap is inconsistent. What is wrong?

2011-02-01 Thread Jeremy Conlin
On Tue, Feb 1, 2011 at 5:00 PM, Benjamin Root ben.r...@ou.edu wrote: On Tue, Feb 1, 2011 at 5:48 PM, Jeremy Conlin jlcon...@gmail.com wrote: I'm trying to create a custom colormap used with pcolormesh, but the results seem inconsistent to me.  I want the following colors -3 x = -2

Re: [Matplotlib-users] Custom colormap is inconsistent. What is wrong?

2011-02-01 Thread Jeremy Conlin
On Tue, Feb 1, 2011 at 6:31 PM, Eric Firing efir...@hawaii.edu wrote: On 02/01/2011 02:18 PM, Benjamin Root wrote: On Tue, Feb 1, 2011 at 6:05 PM, Jeremy Conlin jlcon...@gmail.com mailto:jlcon...@gmail.com wrote:     On Tue, Feb 1, 2011 at 5:00 PM, Benjamin Root ben.r...@ou.edu

Re: [Matplotlib-users] How to add extra ticks to colorbar

2010-09-17 Thread Jeremy Conlin
On Fri, Sep 17, 2010 at 12:44 AM, Scott Sinclair scott.sinclair...@gmail.com wrote: On 16 September 2010 22:52, Jeremy Conlin jlcon...@gmail.com wrote: I have a colorbar which has some ticks, but I would like to add my own ticks without replacing any of the existing ones.  In addition, I would

[Matplotlib-users] How to add extra ticks to colorbar

2010-09-16 Thread Jeremy Conlin
I have a colorbar which has some ticks, but I would like to add my own ticks without replacing any of the existing ones. In addition, I would like to give the ticks a different labels like min and max. Can someone show how this might be done? Thanks, Jeremy

[Matplotlib-users] Math fonts not working after upgrading to MPL 1.0

2010-09-08 Thread Jeremy Conlin
I have trouble getting any symbols or any super/sub scripts to work since I upgraded to 1.0 a few months ago. I always get a message saying that some font isn't found. This occurs whenever I try to put symbols, superscripts, or subscripts in a label, or when I use a log scale (because then it

Re: [Matplotlib-users] Math fonts not working after upgrading to MPL 1.0

2010-09-08 Thread Jeremy Conlin
On Wed, Sep 8, 2010 at 10:42 AM, Tony S Yu tsy...@gmail.com wrote: On Sep 8, 2010, at 11:56 AM, Jeremy Conlin wrote: I have trouble getting any symbols or any super/sub scripts to work since I upgraded to 1.0 a few months ago.  I always get a message saying that some font isn't found

[Matplotlib-users] Reduce image size

2010-08-30 Thread Jeremy Conlin
I have a matplotlib plot that I saved to a pdf image. The plot consists of 1E5 dots plotted with varying colors and opacities. Actually 1E5 black dots with varying opacities and 64 colored markers. The trouble is my image is 11 MB and takes a few seconds to fully display in a PDF reader. I am

Re: [Matplotlib-users] How to improve colorbar scaling?

2010-08-19 Thread Jeremy Conlin
On Wed, Aug 18, 2010 at 10:11 PM, Jae-Joon Lee lee.j.j...@gmail.com wrote: Try cbar.formatter.set_useOffset(False) cbar.formatter.set_scientific(True) cbar.formatter.set_powerlimits((0,2)) It gives me offsetText - x 10^3 and tick labels = [5.0002, 5.0004,...] Yes that is exactly what

Re: [Matplotlib-users] How to improve colorbar scaling?

2010-08-17 Thread Jeremy Conlin
On Mon, Aug 16, 2010 at 6:13 PM, Jae-Joon Lee lee.j.j...@gmail.com wrote: Using the set_powerlimits method didn't help? I couldn't get set_powerlimits or set_scientific to change anything in my colorbar scaling. If I used setOffset(False) then there was no scaling; an improvement, but not

Re: [Matplotlib-users] How to improve colorbar scaling?

2010-08-16 Thread Jeremy Conlin
On Sun, Aug 15, 2010 at 10:49 PM, Jae-Joon Lee lee.j.j...@gmail.com wrote: On Fri, Aug 13, 2010 at 3:34 AM, Jeremy Conlin jlcon...@gmail.com wrote: I have a problem with the scaling of the numbers on a colorbar.  The problem occurs when the numbers used as colorbar labels need to be scaled

[Matplotlib-users] How to improve colorbar scaling?

2010-08-12 Thread Jeremy Conlin
I have a problem with the scaling of the numbers on a colorbar. The problem occurs when the numbers used as colorbar labels need to be scaled (i.e. by 1E3). The colorbar correctly puts the scaling value on the top of the colorbar, but instead of of multiplying by a scale factor, addition is used

[Matplotlib-users] Permission error after installing MPL 1.0 on Mac

2010-07-30 Thread Jeremy Conlin
I recently installed MPL on two Macs, one running 10.6 and another running 10.5. When I try to plot, I get the following error: TclError: couldn't open /Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/matplotlib/mpl-data/images/home.ppm: permission denied After

Re: [Matplotlib-users] No color scaling when using plot_surface. Please help

2010-07-11 Thread Jeremy Conlin
On Friday, July 9, 2010, Benjamin Root ben.r...@ou.edu wrote: Jeremy, I believe that 0.99.1 is fairly old.  I don't know when Axes3D came along, but I am sure you can find it in 0.99.3.  It is most definitely in 1.0, but you might not need to go that far if your distro does not provide it.

Re: [Matplotlib-users] No color scaling when using plot_surface. Please help

2010-07-09 Thread Jeremy Conlin
On Thu, Jul 8, 2010 at 8:41 AM, Jeremy Conlin jlcon...@gmail.com wrote: On Sun, Jul 4, 2010 at 8:38 PM, Benjamin Root ben.r...@ou.edu wrote: Jeremy, The pcolor function can take a vmin and a vmax parameter if you wish to control the colorscaling.  In addition, you can use a special array

Re: [Matplotlib-users] No color scaling when using plot_surface. Please help

2010-07-08 Thread Jeremy Conlin
On Sun, Jul 4, 2010 at 8:38 PM, Benjamin Root ben.r...@ou.edu wrote: Jeremy, The pcolor function can take a vmin and a vmax parameter if you wish to control the colorscaling.  In addition, you can use a special array structure called a masked array to have pcolor ignore special values.

[Matplotlib-users] No color scaling when using plot_surface. Please help

2010-06-30 Thread Jeremy Conlin
I am trying to plot some data over a mesh using the plot_surface method. However when I plot my data, everything is the same color when I expected to get a nice rainbow of colors as in the example: http://matplotlib.sourceforge.net/examples/mplot3d/surface3d_demo.html I have attached a simple

[Matplotlib-users] Unequal size gangplots

2010-06-21 Thread Jeremy Conlin
I have followed this excellent example: http://matplotlib.sourceforge.net/examples/pylab_examples/ganged_plots.html but I would like my plots to be 2/3 and 1/3 of the total height of the figure (I only have 2 plots). What do I have to do to specify the relative sizes of the figures? Thanks,

Re: [Matplotlib-users] Unequal size gangplots

2010-06-21 Thread Jeremy Conlin
On Mon, Jun 21, 2010 at 2:33 PM, Jeffrey Blackburne je...@mit.edu wrote: I have used add_axes() to do this in the past. E.g., import matplotlib.pyplot as plt fig = plt.figure() leftmarg = 0.125   # change these numbers to taste botmmarg = 0.125 width = 0.825 height = 0.825 frac = 2./3.

[Matplotlib-users] Can I make a mplot3d PolyCollection Plot with projection on back wall

2010-04-14 Thread Jeremy Conlin
I want to make a plot similar to this demo: http://matplotlib.sourceforge.net/examples/mplot3d/polys3d_demo.html but also make simple line plots on the back wall of the plot, perhaps with the pyplot.plot command. How can I do this? Thanks, Jeremy

Re: [Matplotlib-users] Can I make a mplot3d PolyCollection Plot with projection on back wall

2010-04-14 Thread Jeremy Conlin
On Wed, Apr 14, 2010 at 9:35 AM, Ben Axelrod baxel...@coroware.com wrote: This example shows how to use 2d plots in a 3d plot: http://matplotlib.sourceforge.net/examples/mplot3d/2dcollections3d_demo.html These examples may also help:

[Matplotlib-users] Failure compiling MPL on Snow Leopard

2010-03-08 Thread Jeremy Conlin
I am trying to compile MPL on Snow Leopard without success. I have a fairly fresh system (10.6.2) with python.org 2.6.4 installed. I have downloaded the MPL trunk with svn. I had to make a small change to the make.osx file because there are some extra . However I still can't get MPL to

[Matplotlib-users] Why do xticklabels and yticklabels always collide?

2010-02-12 Thread Jeremy Conlin
My biggest problem with matplotlib is that the smallest yticklabel and the smallest xticklabel always seem to lie on top of each other (or close to it). See attachment for example. Is there anyway to make it so these don't lie on top of each other? How can I make this the default behavior?

Re: [Matplotlib-users] Why do xticklabels and yticklabels always collide?

2010-02-12 Thread Jeremy Conlin
On Fri, Feb 12, 2010 at 11:30 AM, C M cmpyt...@gmail.com wrote: My biggest problem with matplotlib is that the smallest yticklabel and the smallest xticklabel always seem to lie on top of each other (or close to it).  See attachment for example.  Is there anyway to make it so these don't lie

[Matplotlib-users] Extraneous line drawn using pyplot

2009-10-23 Thread Jeremy Conlin
Hello list. I am having trouble with an extraneous line drawn from my last data point back to the first data point. I I don't quite know why this is happening and was hoping someone could tell me what was wrong. I have attached an example; the commands I used are copied below. Thanks, Jeremy

Re: [Matplotlib-users] Extraneous line drawn using pyplot

2009-10-23 Thread Jeremy Conlin
On Fri, Oct 23, 2009 at 4:16 PM, Jae-Joon Lee lee.j.j...@gmail.com wrote: Your data repeat itself twice. Please check your data and report back if you still see the problem. Regards, Of course it does smacks head. Sorry for bothering the list with my stupidity. Jeremy

[Matplotlib-users] Fatal Python error when importing pyplot

2009-03-09 Thread Jeremy Conlin
I am using Mac OS X 10.5.5 and have installed Enthought's latest Python distribution which includes Matplotlib 0.98.3. I get a fatal python error whenever I try to import matplotlib.pyplot. The exact message I get is: Fatal Python error: Interpreter not initialized (version mismatch?) Abort trap

Re: [Matplotlib-users] Fatal Python error when importing pyplot

2009-03-09 Thread Jeremy Conlin
On Mon, Mar 9, 2009 at 12:50 PM, Jeff Whitaker jsw...@fastmail.fm wrote: Jeremy Conlin wrote: On Mon, Mar 9, 2009 at 12:19 PM, Jeff Whitaker jsw...@fastmail.fmmailto: jsw...@fastmail.fm wrote: Jeremy Conlin wrote: I am using Mac OS X 10.5.5 and have installed Enthought's

Re: [Matplotlib-users] Fatal Python error when importing pyplot

2009-03-09 Thread Jeremy Conlin
On Mon, Mar 9, 2009 at 12:08 PM, John Hunter jdh2...@gmail.com wrote: On Mon, Mar 9, 2009 at 10:43 AM, Jeremy Conlin jerem...@gmail.com wrote: I am using Mac OS X 10.5.5 and have installed Enthought's latest Python distribution which includes Matplotlib 0.98.3. I get a fatal python error

[Matplotlib-users] Installing latest version of matplotlib for enthought python

2009-01-28 Thread Jeremy Conlin
I installed EPD and now would like to install the latest version of matplotlib so I can try out the new CocoaAgg background. I can download the binary mpkg from sourceforge, but it won't work for me because my python version isn't the python from python.org. Can someone help me get this

[Matplotlib-users] Please help with 3d scatter plot

2008-10-27 Thread Jeremy Conlin
I have a function (shown below) that would take a 3D numpy array and plot points in 3D. I recently updated my matplotlib with the latest Enthought Python Distribution and now it doesn't work; I guess matplotlib changed the api a little bit. The first problem arises because there is no

[Matplotlib-users] Two questions regarding axis scaling

2008-09-12 Thread Jeremy Conlin
First question:I know I can do pylab.loglog() to get a log-log plot. I would like to create a log-linear plot. How can I do this? Second question: I would like to plot two sequences on the same figure with two different y-scales, one scale shown on the left and one scale shown on the right.

Re: [Matplotlib-users] os x leopard build step-by-step

2007-11-25 Thread Jeremy Conlin
Thanks for posting these instructions. Forgive me if this has already been hashed out in previous emails, but do the instructions for iPython resolve the readline issues in Leopard? Thanks, Jeremy On Nov 25, 2007 11:12 PM, John Hunter [EMAIL PROTECTED] wrote: A couple of weeks ago I got a new

Re: [Matplotlib-users] Installing under Leopard (Mac OSX 10.5)

2007-11-13 Thread Jeremy Conlin
I am having a similar problem. However I can't seem to get matplotlib to compile at all. It fails when it can't find png.h. At the beginning, it says it can find freetype and libpng, but can't find the appropriate header files. I have found them here:

Re: [Matplotlib-users] Equivalent to Gnuplot histeps style

2007-10-18 Thread Jeremy Conlin
On 10/18/07, Eric Firing [EMAIL PROTECTED] wrote: Jeremy Conlin wrote: On 10/17/07, Charles Seaton [EMAIL PROTECTED] wrote: Jeremy, I ran across the answer to this last week while searching the list for info on datestr2num (both subjects happened to come up in the same exchange

Re: [Matplotlib-users] Equivalent to Gnuplot histeps style

2007-10-18 Thread Jeremy Conlin
On 10/18/07, Eric Firing [EMAIL PROTECTED] wrote: Jeremy Conlin wrote: On 10/18/07, Eric Firing [EMAIL PROTECTED] wrote: Jeremy Conlin wrote: On 10/17/07, Charles Seaton [EMAIL PROTECTED] wrote: Jeremy, I ran across the answer to this last week while searching the list for info

Re: [Matplotlib-users] Equivalent to Gnuplot histeps style

2007-10-17 Thread Jeremy Conlin
On 10/17/07, Charles Seaton [EMAIL PROTECTED] wrote: Jeremy, I ran across the answer to this last week while searching the list for info on datestr2num (both subjects happened to come up in the same exchange). http://www.nabble.com/First-impression-from-a-new-user-tf1716894.html#a4662446