I am rather new to plotly.
When plotting a scatter graph and then plotting a line, how do I set the order of the two elements? Currently, the points are on top but I want it the other way around. I did not find any hint on how to set the order in the forum.
Within scatter traces, the order of display on the screen should match the order in the figureβs data tuple. If you want the line on top, make sure the scatter trace displaying the line shows up later in the figure than the scatter trace showing the markers.
Something like,
import plotly.graph_objs as go
fig = go.Figure(
data=[
go.Scatter(mode='markers', ...),
go.Scatter(mode='lines', ...),
]
)