1
Hello, good afternoon, sir! I am developing a model that will predict the volume of vehicles each day of the year, but I am encountering difficulties because of the functions that make the forecasts seasonalized and that do not contain the quantity inputs. Does anyone have any other idea how I can treat this data to perform prediction on models like ARIMA, x13 Seats or any other command that does the job in a similar way?
Follow my code and mistakes for every attempt:
library(forecast)
Pedagiados=data[,2]
Pedagiados=as.numeric(unlist(Pedagiados)
Pedagiados_TS=ts(Pedagiados,start = c(2015,1),end=c(2019,365),frequency=365)
plot(Pedagiados_TS,xlab='tempo',ylab='Volume',main='Volume 2015-2019')
ajuste=HoltWinters(Pedagiados_TS)
ajuste
prev_hw=forecast(ajuste,h=84,level=95)
plot(prev_hw,xlab='tempo',ylab='Volume',main='Volume veículos ')
prev_hw
require(xlsx)
write.csv2(data.frame(prev_hw),"Previsão HW 1T 2020.csv")
#SARIMA
fit.Volume=Arima(Pedagiados_TS,order=c(1,1,1),seasonal = c(1,1,1), method="ML",lambda=0)
Error in makeARIMA(trarma[[[1L]], trarma[[[2L]], Delta, kappa, Ssinit) : Maximum range supported is 350
With this error, I try to adjust the X13 ARIMA SEATS as follows:
#X13 ARIMA SEATS
require(seasonal)
ajuste_X13=seas(Pedagiados_TS)
However:
Erro: X-13 run failed Errors: - Seasonal period too large. See Section 2.7 of the Reference Manual on program limits - Time series could not be read due to previously found errors - Specify series before user-defined adjustments - Need to specify a series to identify outliers
Any suggestions on how to analyze this time series considering its seasonality and making projections? Thanks in advance
It gets hard to reproduce the problem without your data (the problems seem to be there). Please, edit your question including the result of
dput(data[,2])
. If you can’t share the data, try to find a public set that reproduces the problem.– Tomás Barcellos