2010/10/20 Stefan Mauerberger <stefan.mauerber...@mnet-online.de>:
> I want to make a polar plot with grid not of the full circle but a
> section (e.g. r=[5:6], phi=[-20:30]). The result should look like this:
> http://homepages.physik.uni-muenchen.de/~Stefan.Mauerberger/example.png
> I have tried a lot and had also looked to the examples but my results
> are not satisfying. This example
> http://matplotlib.sourceforge.net/examples/axes_grid/demo_curvelinear_grid.html
>   seems to be highly relevant for my needs but i do not understand it at all.
>
> I tried two different ways:
> Using the option polar=True works fine but I was not able to shrink the
> plot to the section.
> Otherwise transforming the data to cartesian coordinates (e.g.
> pcolor(r*np.sin(phi),r*np.cos(phi),data) ) the data are plotted into a
> box. But in this case I do not know how to draw a grid.

I believe only option (2) will be feasible, I remember a discussion in
past about this to having had the same outcome.

Try here: 
http://matplotlib.sourceforge.net/api/axes_api.html#matplotlib.axes.Axes.pcolor
(*faceted* option).

Notice the next functions on that page, they might help you saving
time, but some of them *might* not work in polar Axes, I'm not sure
which of them if any at all, just be warned.

Make sure you're using 1:1 aspect of the axes containing the pcolor()
Collection, or it will look distorted.

Friedrich

P.S.: If this is your first mpl-users thread, make sure to hit the
reply-to-all button ...

------------------------------------------------------------------------------
Nokia and AT&T present the 2010 Calling All Innovators-North America contest
Create new apps & games for the Nokia N8 for consumers in  U.S. and Canada
$10 million total in prizes - $4M cash, 500 devices, nearly $6M in marketing
Develop with Nokia Qt SDK, Web Runtime, or Java and Publish to Ovi Store 
http://p.sf.net/sfu/nokia-dev2dev
_______________________________________________
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users

Reply via email to