【发布时间】:2020-08-04 13:24:09
【问题描述】:
我想用破折号更新饼图:
@app.callback(
Output('piechart','figure'),
[Input('piechartinput', 'value')]
)
def update_piechart(new_val):
return {px.pie(dfs, names = new_val, values='Wert')}
很遗憾,我收到了这个错误:
Traceback (most recent call last):
File "C:\Users\TO3THY0\.spyder-py3\Dashboard\Dashboard.py", line 153, in update_piechart
return {px.pie(dfs, names = new_val, values='Wert')}
TypeError: unhashable type: 'Figure'
有人可以帮我吗?谢谢!
【问题讨论】:
标签: python dashboard plotly-dash