Adding a new separate figure to existing one

Hi

My 3d figure seems OK. I want to add a new separete figure ( a barcahart) without touching the existing one.
I mean
fig=go.Figure(data=data,layout=layout) # this 3D figure OK
Now I need to put another figure ( barcahart) near to existing 3d figure.

I tried fig.append_trace, but it failed.

How can I add a new separate figure beside the existing one ?

regards

Hi @doga,

We donโ€™t have anything built in right now to support merging multiple figures into a single figure. It is something that weโ€™re considering for version 4 if we have enough time (See https://github.com/plotly/plotly.py/issues/1482).

In the meantime, the way to do this is to use an approach like the โ€œMixed Subplotsโ€ example (https://plot.ly/python/mixed-subplots/).

Hope that helps!
-Jon

Thank you,

I am still dealing with mixed subplot example.

I am not clear on how barchartโ€™s (locations) size and place is formed in the layout in that example ?

regards

you can try adding another trace and repositioning your subplots; however, itโ€™ll be best if you share your code.

thank you

with Mixed Subplot it seems ok now.

1 Like