Learn R Programming

ftsa (version 3.2)

dynupdate: Dynamic updates via BM, OLS, RR and PLS methods

Description

Four methods, namely block moving (BM), ordinary least squares (OLS) regression, ridge regression (RR), penalized least squares (PLS) regression, were proposed to address the problem of dynamic updating, when partial data in the most recent curve are observed.

Usage

dynupdate(data, newdata = NULL, holdoutdata, method = c("ts", "block", 
 "ols", "pls", "ridge"), fmethod = c("arima", "ar", "ets", "ets.na", 
  "rwdrift", "rw"), pcdmethod = c("classical", "M", "rapca"), 
   ngrid = max(1000, ncol(data$y)), order = 6, lambda = 0.01, 
    value = FALSE, interval = FALSE, level = 80, 
     pimethod = c("parametric", "nonparametric"), B = 1000)

Arguments

Value

forecastsAn object of class fts containing the dynamic updated point forecasts.bootsampAn object of class fts containing the bootstrapped point forecasts, which are updated by the PLS method.lowAn object of class fts containing the lower bound of prediction intervals.upAn object of class fts containing the upper bound of prediction intervals.

Details

This function is designed to dynamically update point and distributional forecasts, when partial data in the most recent curve are observed. If method = "classical", then standard functional principal component decomposition is used, as described by Ramsay and Dalzell (1991). If method = "rapca", then the robust principal component algorithm of Hubert, Rousseeuw and Verboven (2002) is used. If method = "M", then the hybrid algorithm of Hyndman and Ullah (2005) is used.

References

J. O. Ramsay and C. J. Dalzell (1991) "Some tools for functional data analysis (with discussion)", Journal of the Royal Statistical Society: Series B, 53(3), 539-572. M. Hubert and P. J. Rousseeuw and S. Verboven (2002) "A fast robust method for principal components with applications to chemometrics", Chemometrics and Intelligent Laboratory Systems, 60(1-2), 101-111. R. J. Hyndman and M. S. Ullah (2007) "Robust forecasting of mortality and fertility rates: A functional data approach", Computational Statistics and Data Analysis, 51(10), 4942-4956. H. Shen and J. Z. Huang (2008) "Interday forecasting and intraday updating of call center arrivals", Manufacturing and Service Operations Management, 10(3), 391-410. H. Shen (2009) "On modeling and forecasting time series of curves", Technometrics, 51(3), 227-238. H. L. Shang and R. J. Hyndman (2011) "Nonparametric time series forecasting with dynamic updating", Mathematics and Computers in Simulation, 81(7), 1310-1324.

See Also

ftsm, forecast.ftsm, plot.fm, residuals.fm, summary.fm

Examples

Run this code
dynupdate(data = ElNino, newdata = ElNino$y[1:4,57], 
          holdoutdata = ElNino$y[5:12,57], method = "ts")
dynupdate(data = ElNino, newdata = ElNino$y[1:4,57], 
          holdoutdata = ElNino$y[5:12,57], method = "block")
dynupdate(data = ElNino, newdata = ElNino$y[1:4,57], 
          holdoutdata = ElNino$y[5:12,57], method = "ols")
dynupdate(data = ElNino, newdata = ElNino$y[1:4,57], 
          holdoutdata = ElNino$y[5:12,57], method = "pls")
dynupdate(data = ElNino, newdata = ElNino$y[1:4,57], 
          holdoutdata = ElNino$y[5:12,57], method = "ridge")
dynupdate(data = ElNino, newdata = ElNino$y[1:4,57], 
          holdoutdata = ElNino$y[5:12,57], method = "block", interval = TRUE)

Run the code above in your browser using DataLab