Hi everyone, I have a problem with plotly. I am visualizing a time series and previously I generated a graph of this style but when I rerun my streamlit application my graph changed completely. I reconfigured my programming environment but nothing seems to work. This is the previous graph (the graph I want):
Sorry but it was the only shot I took, in the bars when you hovered the mouse you could see the detail per day.
Current graph:
Code used:
def chart_time_series(df, n_column):
fig = go.Figure()
fig.add_trace(go.Bar(
name="spend",
x=df["date_start"], y=df[n_column],
xperiod="M1",
xperiodalignment="middle"))
fig.update_layout(title_text = 'Time Series - ' + n_column)
fig.update_traces(marker_color='rgb(255,0,0)')
fig.update_xaxes(showgrid=True, ticklabelmode="period")
fig.update_xaxes(rangeslider_visible=True)
return fig
If someone can help me I will be very grateful.