________________________________
 From: Benjamin Root <ben.r...@ou.edu>
To: Michael Rawlins <rawlin...@yahoo.com> 
Cc: "matplotlib-users@lists.sourceforge.net" 
<matplotlib-users@lists.sourceforge.net> 
Sent: Tuesday, January 17, 2012 10:36 AM
Subject: Re: [Matplotlib-users] placing colorbar when using subplot command
 



On Tue, Jan 17, 2012 at 9:30 AM, Michael Rawlins <rawlin...@yahoo.com> wrote:


>
>I'm relatively new to matplotlib. Trying to place a colorbar in a figure. The 
>code below, placed in a file and executed with python, draws 4 maps using 
>basemap. I've been unable to get a colorbar to show up anywhere on the figure. 
>Ideally I would like the option of placing a colorbar across the bottom, 
>spanning across both bottom map panels.  Also would need the option of placing 
>a colorbar either to the right of or below each map. Uncommenting the two 
>lines under "Here make a colorbar" cause an error. I've used those commands 
>when creating just one map using the figure command.
>
>
>TIA,
>Mike
>
>
>
>

Mike,

Try using the axes_grid1 toolkit to produce your axes objects and to allocate 
enough room for colorbars.

http://matplotlib.sourceforge.net/mpl_toolkits/axes_grid/index.html

Cheers!
Ben Root

P.S. - a little history, there used to be an axes_grid toolkit, but has since 
been superseded by axes_grid1.


Clicking on source code on that page produces an error. For several of the 
graphic on that page, dropping the code into a file and running also produces 
various errors. Being new to this software, having a specific example that I 
can run and then incorporate into my code would be a big help. 

Mike
------------------------------------------------------------------------------
Keep Your Developer Skills Current with LearnDevNow!
The most comprehensive online learning library for Microsoft developers
is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,
Metro Style Apps, more. Free future releases when you subscribe now!
http://p.sf.net/sfu/learndevnow-d2d
_______________________________________________
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users

Reply via email to