Hi. Iโm plotting a stock chart using a dataframe with 1400 rows of intraday data. The target chart is Close price on the Y axis and Date/Time on the X axis. The problem is that rangebreaks=[dict(bounds=["sat", "mon"])]
* does NOT exclude weekends.
I think this may be that Iโm using an ordinal value for the Date/Time. However, If I donโt use an ordinal value, then the chart produces nothing. Below is the code and resulting chart.
Any ideas on a fix?
Thanks,
Dan.
p.s. My system is a new MacBook Pro M1 with 32GB of memory.
Code:
fig2 = px.scatter(df_plot, x='Datetime_Ordinal', y='Close', title='Symbol Name', trendline='ols', trendline_color_override='darkblue')
fig2.update_xaxes(
rangebreaks=[dict(bounds=["sat", "mon"])]
)
fig2.show()
Chart: