Black Lives Matter. Please consider donating to Black Girls Code today.
Dash HoloViews is now available! Check out the docs.

Using slider controls on a 3d surface plot

I’m trying to use Plotly’s Python API to create a slider chart that controls a 3d surface plot. In this link, the example chart controls a line plot. Is there a way that I can replace the line plot with a surface plot similar to one of these here?

Hi @carpenter,

Yes, this should be possible. You’ll need to replace the definition of data in the example above with the definition of the surface traces that you want.

data = [dict(
        visible = False,
        z = ...
        for step in np.arange(0,5,0.1)]

I think the rest of the example should apply as-is.

Hope that helps!