Adding Arbitrary Number of Vertical Lines to a Graph

Hi all,

I’ve got two sets of time series data, the data is not known beforehand.

I would like to plot a vertical line on the same graph as the two sets of time series whenever the two lines cross each other. This could happen any number of times or could not happen at all.

Is this possible with Dash?

Hi Menace,

If you know (or calculate) the intersections (date/time), you can use this, Horizontal and vertical lines and rectangles in Python to plot a vertical line at these points.

Thank you for the suggestion. I managed to get the desired effect with it and a for loop with an if nested in it.

1 Like