The change picked up the top color. However, it looks to me as though the yellowish color is missing from the color bar. I see only 9 colors. The is without tweaking clim.
When I do tweak clim to clim(vmin=-.1, vmax = 0.1), I see the yellowish color, but two of the bluer colors seem to be missing. I see only 8 colors in the color bar.
To: Carol Leger <carol.leger@...392...>
Subject: Re: [Matplotlib-users] Color bar with discrete colors
From: John Hunter <jdhunter@...4...>
Date: Sat, 15 Jan 2005 16:32:48 -0600
"Carol" == Carol Leger <carol.leger@...392...> writes:
> This is how I modified poormans_contour.py:
It's a bug; in the matplotlib/pylab.py function "colorbar", replace
the line that reads
N = 200
N = cmap.N
No need to tweak the clim....
Should cure what ails ya,
Ms. Carol A. Leger
SRI International Phone: (650) 859-4114
333 Ravenswood Avenue G-273
Menlo Park, CA 94025 e-mail: leger@...392...