Hi guys,
I would like to
- give the user the opportunity to change the visibility of traces within a plot
- also keep the chosen visibility in case the underlying trace data has changed.
Whereas the first point is trivial as the user can just click or double-click on the legend entry for a particular trace, I have difficulties implementing the second point as it seems the events
plotly_legendclick
-
plotly_legenddoubleclick
do not update the underlying Python object. I mean that after one of the above click-events occurredc,
self.plot_1.data[number_of_trace_clicked].visible
has still the old value.
Is this
- on purpose?
- a bug?
and how can I achieve the envisaged functionality?