Possible to add tooltips/hovertext to shapes?

Is it possible to add tooltips/hover text to shape objects that are added to a plot? The scenario is I’m using vertical line shapes to indicate when certain events occurred - but most ideally I’d like a note on the event details to be available on hover.

2 Likes

Not directly, shapes don’t come with hover labels unfortunately.

That said, you could easily add hover labels by adding opacity: 0 scatter markers point along your shapes.

1 Like

Hi,
Can you just share a sample code.
Or just a detailed explanation of this will work.
I am also looking to create a hoverText on hovering over a shape.

1 Like