Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

modify pcolor so masked elements are plotted with color specifed in cmap.set_bad #701

Closed
wants to merge 1 commit into from

Conversation

jswhit
Copy link
Contributor

@jswhit jswhit commented Feb 10, 2012

Previously all masked values in X,Y and C were simply not plotted at all. This patch plots the masked values in C (so that those polygons are colored with the color specified by cmap.set_bad), but still skips the masked values in X and Y.

(so that cmap.set_bad does what is expected).  masked locations in X and
Y are skill not plotted at all.
@WeatherGod
Copy link
Member

Just to note that further discussion on the mailing list of this issue raised the point that fixing this problem may inadvertantly break other people's existing code. It may still be worth it to go ahead with this patch, but it should be done with care.

@efiring
Copy link
Member

efiring commented Feb 19, 2012

The present behavior, though anomalous and a historical artifact, is clearly specified in the docstring, so if a change is to be made, it must include the docstring change and a CHANGELOG entry. One could use a kwarg to allow either behavior, with the kwarg initially defaulting to the present behavior.

@mdboom
Copy link
Member

mdboom commented Jun 1, 2012

I agree with @efiring: If there were a kwarg, say "masked_color", that were "none" (default) or "bad" to turn this on and off, I think this PR is probably good to go. That and adding a unit test ;)

@pelson
Copy link
Member

pelson commented Nov 29, 2012

@jswhit - are you able to move this forwards?
I'm keen to reduce the overall number of mpl pull requests and this one is tangibly close!

Cheers,

@pelson
Copy link
Member

pelson commented Jan 9, 2014

PR is 2 years old so I'm closing it. Please feel free to update and re-invigorate this PR and it can be re-opened.

Thanks,

@pelson pelson closed this Jan 9, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants