code that I am using to create a graph.
arimamodel<-ts(dt$Record,start = c(2009,1),frequency = 12) arimamodel fit_Amodel<-auto.arima(arimamodel,seasonal=TRUE) fit_Amodel predict(fit_Amodel) autoplot(forecast(fit_Amodel,h=24)) + ggtitle("Delivery Records Year-Wise") + xlab("(Delivery Year)") + ylab("(Delivery Records)") + theme_bw() + theme(plot.title = element_text(hjust = 0.5))
I have also tried ...
scale_x_continuous(breaks = seq(from= 2009,to=2020, by =2 ))
it's throwing an error: 'origin' must be supplied'
would someone please tell me how to plot it desired way.