Hi,
I need help.
i have 2 surfaces that i need to animate simultaneously.
If I just the 2 surfaces in the frame sequentially, not surprisingly, in the animation - each surface appears and disappears alternatively. How can i get the 2 surfaces in the animation concurrently ?
Below is the code :
…
surface1 = go.Surface(x=x1[1], y=y1[1], z=z1[1])
surface2 = go.Surface(x=x2[1], y=y2[1], z=z2[1])
load frames
frames=[]
for t in range(1,10):
frames.append(dict(data=[dict(type=‘surface’,x=x1[t], y=y1[t], z=z1[t])] ))
frames.append(dict( data=[dict(type=‘surface’,x=x2[t],y=y2[t],z=z2[t])] ))
layout = dict(
scene=dict(xaxis=(dict(range=[-10, 10], autorange=False)),
yaxis=(dict(range=[-10, 10], autorange=False)),
zaxis=dict(dict(range=[-10, 10], autorange=False)),
aspectratio=dict(x=1, y=1, z=1),
),
)
fig = go.Figure(data=[surface1, surface2], layout=layout,frames=frames)
iplot(fig)
Thanks for your help