[Matplotlib-users] clever folks, grid subsetting / extracting

2010-11-05 Thread John
Clever folks, Is there an algorithm, or known method to extract a subset of one grid to match another. I have two grids, one nested, the other global. In general they are regular lat/lon grids. Also, in general they are 0.5 degree lat/lon. However, I would like to make this as general as possible.

[Matplotlib-users] colormap plot

2010-11-05 Thread Daniele Nicolodi
Hello, I have a really dummy question. I would like to plot an x, y, z table so that each region of the plot area defined by the coordinates (x, y) corresponds a color given by the value of z. I suppose this is a kind of basic functionality, but I'm unable to find the right function into matplotli

Re: [Matplotlib-users] colormap plot

2010-11-05 Thread Scott Sinclair
On 5 November 2010 13:33, Daniele Nicolodi wrote: > I would like to plot an x, y, z table so that each region of the plot > area defined by the coordinates (x, y) corresponds a color given by the > value of z. I suppose this is a kind of basic functionality, but I'm > unable to find the right func

Re: [Matplotlib-users] colormap plot

2010-11-05 Thread Scott Sinclair
On 5 November 2010 14:05, Scott Sinclair wrote: > You probably want imshow, pcolor, pcolormash or matshow I meant pcolormesh... -- The Next 800 Companies to Lead America's Growth: New Video Whitepaper David G. Thomson, a

[Matplotlib-users] automatically choose different line markers

2010-11-05 Thread Neal Becker
How can I automatically cycle through distinctive line markers? I want a semilog plot, composed of a number of lines. Each line should have a different color and marker. Cycling through the colors is automatic, but not the markers. BTW, shouldn't this behavior be the default? I would just lik

[Matplotlib-users] Dealing with Multiple figures

2010-11-05 Thread John M. Densmore (Cont, ARL/WMRD)
Hi All, I have multiple figures set up at the start of my code. through out the script I add data to the plots and at the end I would like to set all the figure parameters, like xlim, ylim, legend etc. But I can not figure out how to do it. Eample code fig1 = plt.figure(1) ax1 = fig1.add_subplo

Re: [Matplotlib-users] automatically choose different line markers

2010-11-05 Thread Aman Thakral
Hi, The best way to do this is to use a generator: import itertools import matplotlib.pyplot as plt import numpy as np def _ncycle(iterable,n): """ Method to create a generator from an iterable. It keeps the current position of the iterable in memory. Each time the next() metho

Re: [Matplotlib-users] recipes in the docs

2010-11-05 Thread Oz Nahum Tiram
A small suggestion to the examples ... I really like the new subplot mechanism, so I tried it: fig, (ax1, ax2, ax3, ax4) = plt.subplots(2, 2, sharex=True, sharey=True) And it actually gave me the following error: Traceback (most recent call last): File "tes.py", line 21, in f, (ax1, ax2,

Re: [Matplotlib-users] Dealing with Multiple figures

2010-11-05 Thread Ryan May
On Fri, Nov 5, 2010 at 7:12 AM, John M. Densmore (Cont, ARL/WMRD) wrote: > Hi All, > I have multiple figures set up at the start of my code. through out the > script I add data to the plots and at the end I would like to set all > the figure parameters, like xlim, ylim, legend etc. But I can not f

Re: [Matplotlib-users] stem plots:

2010-11-05 Thread Alan G Isaac
On 10/25/2010 9:23 AM, Stan West wrote: > markerline.set_zorder(stemlines[0].get_zorder() + 0.1) Thanks. Now I can easily get what I want. But back to the underlying question: do people really prefer the stems to overlay the markers? I.e., are the ``stem`` defaults possibly incorrect? Thanks,

Re: [Matplotlib-users] Can't force draw

2010-11-05 Thread starz1010101
Fixed by switching the backend from WXAgg to MacOSX. starz1010101 wrote: > > I can't force pyplot to draw in the middle a function. For example, this > function does not plot the sine before the user prompt, only after the > entire function executes: > > import matplotlib.pyplot as plt > im