-
Notifications
You must be signed in to change notification settings - Fork 320
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
Allow hiding legend in plots #351
Comments
I'm trying to understand the motivation behind this issue - why would you want to hide the legend on a visualization? |
cc @isarth23 I know you consider this just a visual bug, but isn't legend in this case just unnecessary distraction? It is clear which bar represents what in this case (we should however solve the overflow). In general, I would consider importance of the legend case by case, but providing flexibility to remove it when needed is a plus that folks might appreciate. However, I am by no means a data viz expert so I may be wrong on this one. |
In this particular vis, color-encoding the bars is not useful. Removing the color encoding will make the legend go away. |
Yeah, but it seemed nice with different colors, can be added plus to include but not necessary. |
I have another use case where hiding the legend is important. I am marking the items that were selected via events using different color, but I don't want them to appear in the legend as 2 groups. |
via @isarth23
Proposal: Add
legend
prop toplot_card
, defaults toTrue
.Implementation note:
chart.legend(false)
is all it takes.cc @lo5 @geomodular
The text was updated successfully, but these errors were encountered: