[Matplotlib-users] Adding image to a plot

2014-03-01 Thread Asma Riyaz
Hi, I am trying to insert a .png image to the right side of the plot and following the code mentioned here:Combine picture and plot with Python Matplotlib Here is what I have tried: import numpy as npfrom

[Matplotlib-users] Matplotlib + py3 + gtk3

2014-03-01 Thread Jon Roadley-Battin
>On 02/27/2014 06:58 PM, Jon Roadley-Battin wrote: >> Good evening, >> >> I am at present migrating an application of mine from py27+pygtk (with >> mpl) to py33+pygobject (gtk3) >> >> Unfortunately I am unable to use >> >> from matplotlib.backends.backend_gtk3agg import FigureCanvasGTK3Agg as

Re: [Matplotlib-users] How can I put a white area in the middle of colorbar showing the masked data?

2014-03-01 Thread Eric Firing
On 2014/03/01 11:03 AM, ChaoYue wrote: > The most correct way might be to design a new colormap with white color > exactly in the middle, however this is very tedious, especially if I > want to try > different colormaps. so the alternative approach would be to set the values > falling in (-1,1) as

Re: [Matplotlib-users] How can I put a white area in the middle of colorbar showing the masked data?

2014-03-01 Thread ChaoYue
Hi Eric, thanks for answering. I updated the attached figure. The idea is, we want to show the tree cover difference, but to make the negative and positive values very contrastive, we would like to assign the values falling in small range of change (in the figure, it's -1 to 1) as blank (or gray),

Re: [Matplotlib-users] How can I put a white area in the middle of colorbar showing the masked data?

2014-03-01 Thread Eric Firing
On 2014/03/01 9:57 AM, Chao YUE wrote: > Dear all, > > In many cases in geoscience mapping we want to show the some missing values > as some special color in the colorbar. like attached one. > > I know there is one method in matplotlib colormap called "set_bad", official > docs says: > > Set color

Re: [Matplotlib-users] How can I put a white area in the middle of colorbar showing the masked data?

2014-03-01 Thread Chao YUE
sorry, the attached file may lack surfix type, here is the correct one. Cheers, chao On Sat, Mar 1, 2014 at 8:57 PM, Chao YUE wrote: > Dear all, > > In many cases in geoscience mapping we want to show the some missing values > as some special color in the colorbar. like attached one. > > I kn

[Matplotlib-users] How can I put a white area in the middle of colorbar showing the masked data?

2014-03-01 Thread Chao YUE
Dear all, In many cases in geoscience mapping we want to show the some missing values as some special color in the colorbar. like attached one. I know there is one method in matplotlib colormap called "set_bad", official docs says: Set color to be used for masked values. But I don't know how to