title: How to change data and graph using buttons in plotly python?
body: <p>Based on this code directly from plotly's tut page:</p>
  
  <p><a href="https://plot.ly/python/dropdowns/" rel="noreferrer">https://plot.ly/python/dropdowns/</a></p>
  
  <p>Now, what if I want to change not just the chart type but rather the data source and its chart type? 
  Is it possible? </p>
  
  <p>EDIT:</p>
  
  <p>I've played with this settings:</p>
  
  <pre><code>data1 = go.Surface(z=df.values.tolist(), colorscale='Viridis')
  data2 = go.Heatmap(z=df.values.tolist())
  
  buttons=list([   
              dict(
                  args=[data1],
                  label='3D Surface',
                  method='restyle'
              ),
              dict(
                  args=[data2],
                  label='Heatmap',
                  method='restyle'
              )             
          ])
  </code></pre>
  
  <p>However, the graphs are shown, but overlayed. And when I click any item in the dropdown menu, the graph is completely gone.</p>