-
-
Notifications
You must be signed in to change notification settings - Fork 407
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
Fixed plot_trace legend overwriting by chain legend (Issue #2320) #2334
Conversation
Test failures seem to be from an issue with checking axes[0,0] for the chain legend- could this test be modified? |
Yes, it needs to be modified. Once you have you can check the " Includes new or updated tests to cover the new feature" box |
Sure, will modify test as appropriate |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If you click at the "details" link of the failing job you'll eventually get to this page: https://dev.azure.com/ArviZ/ArviZ/_build/results?buildId=6712&view=logs&jobId=52053870-44e4-57aa-b540-f1a2d094f440&j=52053870-44e4-57aa-b540-f1a2d094f440&t=b4fdbffc-b4d0-53ca-c47c-a902d6813a77.
It looks like there is a trailing whitespace somewhere. You can run black which will get rid of it and if necessary to any other formatting changes needed. With that and adding a line to the Changelog in maintenance and bug fixes section it will be ready to merge.
Sure, just did that. Seems some |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #2334 +/- ##
=======================================
Coverage 86.84% 86.84%
=======================================
Files 123 123
Lines 12745 12745
=======================================
Hits 11068 11068
Misses 1677 1677 ☔ View full report in Codecov by Sentry. |
It's ok yeah, don't worry. |
Let's add a bullet point to the changelog to check the last box and merge |
Sure, just did that |
Description
Addresses Issue #2320 , where chain legend seemed to overwrite fist subplot legend that displays coord combinations.
When the chain legend is created (
.legend(handles=handles, title="chain", loc="upper right")
), passing this to second subplot in the plot generated, which is the first trace plot (ax.figure.axes[1]
) instead of the first subplot, which is the first density plot and already has a legend (ax.figure.axes[0]
) prevents overwriting. As per @OriolAbril 's suggestion in the issue comments of #2320 .Here are the plots now generated with this small edit, with no overwriting:
Checklist
📚 Documentation preview 📚: https://arviz--2334.org.readthedocs.build/en/2334/