Black Lives Matter. Please consider donating to Black Girls Code today.
Dash HoloViews is now available! Check out the docs.

How to specify which axes a "shapes" object should use?

If one has multiple axes, e.g. https://plot.ly/python/axes/#fixed-ratio-axes

Then how do you also add a shape, e.g. https://plot.ly/python/shapes/#vertical-and-horizontal-lines-positioned-relative-to-the-axes and specify which axes the shape should use.

Normally, when doing a plot you would do something like: yaxis = "y2". But this does not work with shapes.

Thanks,
Peter

You can see all of the shape options here: https://plot.ly/python/reference/#layout-shapes

xref and yref are the properties to use.

1 Like

Great! Thank you very much for your help.