You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When one adds a trace to an existing plot, it will be drawn on top of earlier defined traces. However, when one adds a shape, it will always be on top of everything else. Example:
library(plotly)
p<- plot_ly(economics, x=date, y=uempmed, name="unemployment",line=list(color="yellow"))
p<- layout(p, title='Highlighting with Rectangles',
shapes=list(
list(type="rect",
fillcolor="blue", line=list(color="blue"), opacity=0.5,
x0="1980-01-01", x1="1985-01-01", xref="x",
y0=4, y1=12.5, yref="y")))
p# Shapes are in front of the linep<- add_trace(economics, x=date, y=uempmed, name="unemployment",line=list(color="white"))
p# Shapes are still in front of the line
Is this intended or unwanted behaviour?
Using plotly_2.0.18.
The text was updated successfully, but these errors were encountered:
When one adds a trace to an existing plot, it will be drawn on top of earlier defined traces. However, when one adds a shape, it will always be on top of everything else. Example:
Is this intended or unwanted behaviour?
Using plotly_2.0.18.
The text was updated successfully, but these errors were encountered: