Skip to content

Only label vertical lines in acorr #9945

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

Merged
merged 2 commits into from
Dec 7, 2017
Merged

Conversation

dstansby
Copy link
Member

@dstansby dstansby commented Dec 6, 2017

Fixes #9944. I also got very confused with what c was in the code, so I've renamed it correls.

a = self.vlines(lags, [0], c, **kwargs)
a = self.vlines(lags, [0], correls, **kwargs)
# Make label empty so only vertical lines get a legend entry
kwargs['label'] = ''
Copy link
Member Author

Choose a reason for hiding this comment

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

This is the actual fix

Copy link
Member

Choose a reason for hiding this comment

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

might be better to kwargs.pop('label', '') so that if the user has not passed in a label the axhline does the default thing?

@tacaswell tacaswell added this to the v2.2 milestone Dec 6, 2017
@anntzer
Copy link
Contributor

anntzer commented Dec 7, 2017

Test failure seems unrelated.

@anntzer anntzer merged commit baa5f8e into matplotlib:master Dec 7, 2017
@MichaelClerx
Copy link

Thanks!

@dstansby dstansby deleted the acorr-legend branch December 7, 2017 10:23
@QuLogic QuLogic modified the milestones: needs sorting, v2.2.0 Feb 12, 2018
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.

5 participants