## Solved – Forecasting with holiday dumthe variables

I have an example of call center data for 2013. There are 261 days of data (excluding weekends). For 2013, I have included a holiday dummy variable (holiday) for the days where there were no stats. For 2014, I have also included a future holiday dummy variable (holidayf). My objective is to assess how accurate … Read more

## Solved – Estimating out-of sample forecast for an ARIMA model

I’m trying to estimate the out-of sample forecast of an ARIMA model, I tried the code below, but it totally doesn’t work! for(i in 1:83) { mod[i] <- arima(window(betahat[,1], start=1, end=109+i),order=c(1,0,0),include.mean=TRUE) pre[i] <- predict(mod[i],12) error[i] <- pre[i]\$pred[12]-betahat[(109+i+12),1] } the data are taken monthly and I divided the data into 2 subsets, the first composed by … Read more

## Solved – C# ARMA library

Closed. This question is off-topic. It is not currently accepting answers. This question appears to be off-topic because EITHER it is not about statistics, machine learning, data analysis, data mining, or data visualization, OR it focuses on programming, debugging, or performing routine operations within a statistical computing platform. If the latter, you could try the … Read more

## Solved – How to train the Model in Time Series with Holiday, Weekends

I am working on time series to forecast the number of inbound calls for next 1 month on a daily basis. I built a model using auto.arima and forecasted. My forecasting data is showing gradually increasing no. of calls irrespective of holiday or weekend. (I have data for 2 months Aug-1-2016 to Dec-31- 2016. Here … Read more

## Solved – Transforming a time series with a negative number

I have been given data to forecast however it has a negative figure within the data which then, when doing a log transformation to make the series stationary, the ARIMA script i have written won't work. datan<-c(144627.7451,575166.2487,854245.7137,1230639.153,1160052.421,479928.7072,-261427.4238,1181746.229,168251.621,556741.5149,1840484.518,1704679.404,1878380.278,1865288.502,1849340.253,1965974.112,2093192.242,1912399.391,2633179.421,2134618.008,2070856.492,1238565.331) freqdata<-4 startdata<-c(9,2) horiz<-4 datats<-ts(datan,frequency=freqdata,start=startdata) force.log<-"log" datadates<-as.character(c("9q2","9q3","9q4","10q1","10q2","10q3","10q4","11q1","11q2","11q3","11q4","12q1","12q2","12q3","12q4","13q1","13q2","13q3","13q4","14q1","14q2","14q3")) dataMAT<-matrix(0,ncol=freqdata,nrow=(length(datats)+freqdata),byrow=TRUE) for (i in 1:freqdata) {dataMAT[,i]<-c(rep(0,length=i-1),lag(datats,k=-i+1),rep(0,length=freqdata-i+1))} dataind<-dataMAT[c(-1:(-freqdata+1),-(length(dataMAT[,1])-freqdata+1):-(length(dataMAT[,1]))),] dataind2<-data.frame(dataind) lm1<-lm(X1~.,data=dataind2) lm2<-lm(X1~X2+dataind2[,length(dataind2[1,])],data=dataind2) library(lmtest) library(car) … Read more

## Solved – Transforming a time series with a negative number

I have been given data to forecast however it has a negative figure within the data which then, when doing a log transformation to make the series stationary, the ARIMA script i have written won't work. datan<-c(144627.7451,575166.2487,854245.7137,1230639.153,1160052.421,479928.7072,-261427.4238,1181746.229,168251.621,556741.5149,1840484.518,1704679.404,1878380.278,1865288.502,1849340.253,1965974.112,2093192.242,1912399.391,2633179.421,2134618.008,2070856.492,1238565.331) freqdata<-4 startdata<-c(9,2) horiz<-4 datats<-ts(datan,frequency=freqdata,start=startdata) force.log<-"log" datadates<-as.character(c("9q2","9q3","9q4","10q1","10q2","10q3","10q4","11q1","11q2","11q3","11q4","12q1","12q2","12q3","12q4","13q1","13q2","13q3","13q4","14q1","14q2","14q3")) dataMAT<-matrix(0,ncol=freqdata,nrow=(length(datats)+freqdata),byrow=TRUE) for (i in 1:freqdata) {dataMAT[,i]<-c(rep(0,length=i-1),lag(datats,k=-i+1),rep(0,length=freqdata-i+1))} dataind<-dataMAT[c(-1:(-freqdata+1),-(length(dataMAT[,1])-freqdata+1):-(length(dataMAT[,1]))),] dataind2<-data.frame(dataind) lm1<-lm(X1~.,data=dataind2) lm2<-lm(X1~X2+dataind2[,length(dataind2[1,])],data=dataind2) library(lmtest) library(car) … Read more

## Solved – Inventory control – first order quantity of periodic order quantities model

I Have read "Manufacturing Planning and Control for Supply Chain Management 6th Edition" by F.Robert Jacobs. I found the problem on the Periodic Order Quantities (POQ). As I know POQ calculation is after calculate the Economic Order Quantity (EOQ). In the book contained an example problem : To calculate EOQ from the above data using … Read more

## Solved – Inventory control – first order quantity of periodic order quantities model

I Have read "Manufacturing Planning and Control for Supply Chain Management 6th Edition" by F.Robert Jacobs. I found the problem on the Periodic Order Quantities (POQ). As I know POQ calculation is after calculate the Economic Order Quantity (EOQ). In the book contained an example problem : To calculate EOQ from the above data using … Read more

## Solved – Holt Winters with exogenous regressors in R

I need to forecast using HoltWinters with regression parameters using R. But I found there is not any option of xreg in HoltWinters function in R. I thought to use auto.arima with xreg option but my HoltWinters is performing better than auto.arima without any regression parameters. Can you please suggest me how to incorporate xreg … Read more

## Solved – Holt Winters with exogenous regressors in R

I need to forecast using HoltWinters with regression parameters using R. But I found there is not any option of xreg in HoltWinters function in R. I thought to use auto.arima with xreg option but my HoltWinters is performing better than auto.arima without any regression parameters. Can you please suggest me how to incorporate xreg … Read more