Which one is faster with line plot? (go or px?)

Hi,
I created 1 page dashboard for my dataset. I have about 40 different variables and more than 400k row as timeseries data.
And my desigh is like this:

Everything is clear and it works well BUT IT IS KINDA SLOW.

I wanna see 3 different variable at the same time but with different combination.
Every time i change a variable, it take about 8-10second to render.
Actually i check this in notebook (ipynb notebook) and i saw the thing that takes time this much is rendering.

Now i use go.scatter() with market= β€˜line’.

I wanna know if i can reduce the rendering time?

The difference with px.scatter (or px.line) is that if the data exceeds a certain number of points (1000 from memory), it uses go.Scattergl instead of go.Scatter under the hood. And Scattergl has much better performance on large number of points (rendering on canvas instead of via svg).

2 Likes

Also ICYMI, here is a great guide we wrote last year: px vs go - Creating and Updating Plotly Figures

1 Like