My forecasting variable(monthly sales) is seasonal and wanted to include seasonality in the auto Arima function with regressors.
The distribution of monthly sales data is shown below:
I have used the below code:
#Creating a time-series object FA = ts(na.omit(usFaceAvg[yrAndMo < endForTsTrain & yrAndMo >= startForTsTrain,]$faceAvg), frequency=12,) #Fitting an Arima model with regressor and for a seasonal time series usFaceAvgArima <- auto.arima(FA, trace = F, ic = c("bic"), xreg = tempUsSumOfFaceCountryTrainRegressor, seasonal = TRUE) #Forecasting usFaceAvgArima.forecast <- data.table(timeHorizon[yrAndMo >= endForTsTrain], usFaceAvgForecast = forecast(usFaceAvgArima, 12, xreg = tempUsSumOfFaceCountryTestRegressor)$mean)
Is this correct? Should I create dummy binary variables for seasonality and use them as regressors?
I tried to use without considering seasonality (Seasonal = FALSE & not specifying the frequency in ts()), but the forecast remained the same.
How can I successfully include the prevailing seasonality in the monthly sales data?
Any inputs will be appreciated.