โœŠ๐Ÿฟ Black Lives Matter. Please consider donating to Black Girls Code today.
๐Ÿ“Š Dash 2.0 is Arriving. Register here.

Delete plotly graph after saving in python

Hello,

I recently noticed that if I first create a boxplot which has 3 x-axis variables, then create a new blox plot with 6 x-axis variables, the second one will only plot the first 3 variables. These two plots were done in a loop, and if I do them separately, there would be no issue.

My guess is that I should somehow clear the layout or memory after the first plot? What is the appropriate way to do so please? I am new to plotly - any suggestion is appreciated. Thank you.

(For each figure, I save them via:

fig = go.Figure(data=traces, layout=layout) 
py.offline.plot(fig, filename = outputPlotFile, auto_open=False)

)

Hi @DVA, welcome!

Could you add a small example that replicates the problem youโ€™re seeing? That will make it a lot easier for folks to help you out :slight_smile: Thanks!

-Jon