Skip to content

Add a "density" kwarg to hist2d #11070 #12436

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

Closed
wants to merge 0 commits into from
Closed

Conversation

thoo
Copy link
Contributor

@thoo thoo commented Oct 7, 2018

Fix #11070

@anntzer
Copy link
Contributor

anntzer commented Oct 15, 2018

normed should be pushed all the way to the end to avoid backcompat issues.

@thoo
Copy link
Contributor Author

thoo commented Oct 15, 2018

@anntzer Could you elaborate more? Thanks.

@ImportanceOfBeingErnest
Copy link
Member

What the above comment means is that the normed argument should appear last in the list of arguments, similar to how it's been done in #8993.

Copy link
Member

@timhoffm timhoffm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The changes in the signature must also be propagated to pyplot.py. To do so, please run python tools/boilerplate.py to update the auto-generated part of pyplot.py and add the result to the commit.

@@ -6865,7 +6876,16 @@ def hist2d(self, x, y, bins=10, range=None, normed=False, weights=None,
in effect to gamma correction) can be accomplished with
`.colors.PowerNorm`.
"""
if density is not None and normed is not None:
raise ValueError("kwargs 'density' and 'normed' cannot be used "
"simultaneously. "
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This could be re-wrapped to save a line.

@thoo
Copy link
Contributor Author

thoo commented Oct 16, 2018

@timhoffm Thanks.

@timhoffm
Copy link
Member

Unfortunately, our master branch has evolved since you branched your local copy. Therefore the pyplot code you could generate does not fit to the current master anymore. Please rebase your branch to the current upstream master (ask if you need advice how to do it).

@thoo
Copy link
Contributor Author

thoo commented Oct 16, 2018

@timhoffm Thanks for the help. I did git pull --rebase origin master to rebase on my branch. And regeneratepyplot and push it back to my repository. Please let me know if it is still not right.

@ImportanceOfBeingErnest
Copy link
Member

Seems you have removed any commits from this PR. Here is what the documentation tells about rebasing.

@thoo
Copy link
Contributor Author

thoo commented Oct 16, 2018

@timhoffm @ImportanceOfBeingErnest Thank for the reference. I went too far before I saw your comment. :) Here is my new attempt. Thanks for the help.

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.

4 participants