'plotly.graph_objs.Line deprecated
I'm getting this message:
plotly.graph_objs.Line is deprecated. Please replace it with one of the following more specific types
- plotly.graph_objs.scatter.Line
- plotly.graph_objs.layout.shape.Line
Any suggestion on how could I fix it? Code:
mortalidade_covid = round((covid_mortes/covid_casos)*100,2)
datas = mortalidade_covid.index
fig = go.Figure(data=[
go.Line(name='Mortalidade em %', x=datas, y=mortalidade_covid, mode="lines+markers")
])
fig['layout'].update(title="Taxa de Mortalidade", title_x=0.5, xaxis_title='Meses', yaxis_title='Taxa de Mortalidade')
fig.show()
Solution 1:[1]
Simply replace go.Line with go.Scatter.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | Davide_sd |
