I am using plotly in Jupyter Notebook with Python to generate multiple 3D plots. All the data exists as points and thus is plotted with Scatter3d. I am trying to add a time slider to this 3D data like this 2D example here:
My plot looks like this right now:
Each of the traces plotted has a date associated with it, so i can group them by month or whatever time frame. I don’t care about the “animation” but the slider on the bottom would be nice, and i can’t seem to make any progress. My code to plot these circles is below:
Code:
i=0
trace=go.Scatter3d(x=Data['X'][i],y=Data['Y'][i],z=Data['Z'][i])
layout=go.Layout(margin={'l': 0, 'r': 0, 'b': 0, 't': 0})
plot_figure = go.Figure(data=trace, layout=layout)
i=1
while i < len(Data):
plot_figure.add_trace(go.Scatter3d(x=Data['X'][i],y=Data['Y'][i],z=Data['Z'][i],
error_z=dict(type='constant',
value=Data['Error Top'][i],
valueminus=-Data['Error Bottom'][i],
thickness=0),
surfaceaxis=1,
surfacecolor=Data['Colors'][i],
mode='lines',
line=dict(color=Data['Colors'][i])))
i=i+1
Any help would be appreciated! Thanks in advance.