Hello, I am trying to app dropdown menus in my charts. The first one is Choropleth map.
After creating the map, i want to color the map according to selected input from drop down menu. Df includes two columns for âConfirmedâ and âDeathsâ
The code is below and does not work.
Thanks for your response , it helped so much ! In case you want to help more, i have one question.
I created a pie plot and want to update labels and values. At first, i created two traces and used visible to just hide one of the traces. But i donât want to use traces. Below is my code and just does not update graph but updates titles. What is the problem in the code ! Thank you in advance.
fig = go.Figure(go.Pie(labels=pie_chart_confirmed[âCountry/Regionâ], values=pie_chart_confirmed[âConfirmedâ], textinfo=âlabel+percentâ, name =âConfirmedâ))
If you modify values and labels, i.e. data (values) , and a data attribute (labels) you have to call the restyle method, not update, because the update method modifies both data and layout.