I have a chart where I don't know the number of x Axis. The x axis is date values. The number can be from 10 days to 750 days.
The following code minimizes the number of x axis values. Please see image. How do I add the min and max date value to the beginning and end of the x axis?
xNum = math.ceil(df1.shape[0] / 15)
xTicks = 10
if xNum > 10:
xTicks = xNum
plt.xticks(x[::xTicks], rotation=45)