Re: [Matplotlib-users] colorbar() fix limit on Heat map

2008-08-11 Thread John Hunter
On Mon, Aug 11, 2008 at 8:31 AM, Jeff Whitaker <[EMAIL PROTECTED]> wrote:

> Have you checked out the pylab examples?  For me, they are the best way
> to learn how to use matplotlib effectively.

In particular:

[EMAIL PROTECTED]:examples> find . -name "*.py"|xargs grep -il colorbar
./animation/dynamic_image_wxagg2.py
./tests/backend_driver.py
./pylab_examples/multi_image.py
./pylab_examples/contourf_demo.py
./pylab_examples/contourf_log.py
./pylab_examples/subplots_adjust.py
./pylab_examples/contour_image.py
./pylab_examples/contour_demo.py
./pylab_examples/pcolor_demo.py
./pylab_examples/image_masked.py
./pylab_examples/poormans_contour.py
./pylab_examples/hexbin_demo.py
./pylab_examples/line_collection2.py
./pylab_examples/pcolor_log.py
./pylab_examples/scatter_demo2.py
./pylab_examples/griddata_demo.py
./pylab_examples/hexbin_demo2.py
./api/colorbar_only.py
./api/patch_collection.py

-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users


Re: [Matplotlib-users] colorbar() fix limit on Heat map

2008-08-11 Thread Jeff Whitaker
stuartornum wrote:
> Jeff,
>
> That worked perfectly ! Thank you.
>
> One more question... how would I change the colour scheme of the colorbar()?
>
> Thanks again
>   
Stuart:  Use the cmap argument to specify a color map.

Have you checked out the pylab examples?  For me, they are the best way 
to learn how to use matplotlib effectively.

-Jeff


-- 
Jeffrey S. Whitaker Phone : (303)497-6313
NOAA/OAR/CDC  R/PSD1FAX   : (303)497-6449
325 BroadwayBoulder, CO, USA 80305-3328


-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users


Re: [Matplotlib-users] colorbar() fix limit on Heat map

2008-08-11 Thread stuartornum

Jeff,

That worked perfectly ! Thank you.

One more question... how would I change the colour scheme of the colorbar()?

Thanks again
-- 
View this message in context: 
http://www.nabble.com/colorbar%28%29-fix-limit-on-Heat-map-tp18923300p18925645.html
Sent from the matplotlib - users mailing list archive at Nabble.com.


-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users


Re: [Matplotlib-users] colorbar() fix limit on Heat map

2008-08-11 Thread Jeff Whitaker
stuartornum wrote:
> Hi All,
>
> You may remember from my previous post I was having problems plotting a
> heatmap, however Pete came through for me and made it work.
>
> Anyway, I have almost finished what I want to do. The only issue is fixing
> the colorbar() range limit.
>
> Sometimes the my values are 0.01 to 0.2 for example, and other times there
> 0.01 to 0.99.
>
> So what happens it the colorbar() automagically adjusts the gradient
> according to my values, however I do not want it to do that, I want the
> graph to be consistantly 0 - 1 (blue - red).
>
> I have tried things like colorbar(0,1), however no luck.
>
> If you could let me know how to fix the range, I would be very grateful.
>
> Regards
>   
Stuart:  Use the vmin/vmax keyword arguments if your are using imshow or 
pcolor/pcolormesh.  If you are using contourf,  just specify the contour 
levels to span the range 0-1 (i.e. clevs=linspace(-1,1,15)).

-Jeff

-- 
Jeffrey S. Whitaker Phone : (303)497-6313
NOAA/OAR/CDC  R/PSD1FAX   : (303)497-6449
325 BroadwayBoulder, CO, USA 80305-3328


-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users


[Matplotlib-users] colorbar() fix limit on Heat map

2008-08-11 Thread stuartornum

Hi All,

You may remember from my previous post I was having problems plotting a
heatmap, however Pete came through for me and made it work.

Anyway, I have almost finished what I want to do. The only issue is fixing
the colorbar() range limit.

Sometimes the my values are 0.01 to 0.2 for example, and other times there
0.01 to 0.99.

So what happens it the colorbar() automagically adjusts the gradient
according to my values, however I do not want it to do that, I want the
graph to be consistantly 0 - 1 (blue - red).

I have tried things like colorbar(0,1), however no luck.

If you could let me know how to fix the range, I would be very grateful.

Regards
-- 
View this message in context: 
http://www.nabble.com/colorbar%28%29-fix-limit-on-Heat-map-tp18923300p18923300.html
Sent from the matplotlib - users mailing list archive at Nabble.com.


-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users