IDEAS home Printed from https://ideas.repec.org/p/fgv/eesptd/498.html
   My bibliography  Save this paper

Cross-validation based forecasting method: a machine learning approach

Author

Listed:
  • Pinto, Jeronymo Marcondes
  • Marçal, Emerson Fernandes

Abstract

Our paper aims to evaluate two novel methods on selecting the best forecasting model or its combination based on a Machine Learning approach. The methods are based on the selection of the ”best” model, or combination of models, by crossvalidation technique, from a set of possible models. The first one is based on the seminal paper of Granger-Bates (1969) but weights are estimated by a process of cross-validation applied on the training set. The second one selects the model with the best forecasting performance in the process described above, which we called CvML (Cross-Validation Machine Learning Method). The following models are used: exponential smoothing, SARIMA, artificial neural networks and Threshold autoregression (TAR). Model specification is chosen by R packages: forecast and TSA. Both methods – CvML and MGB - are applied to these models to generate forecasts from one up to twelve periods ahead. Frequency of data is monthly. We run the forecasts exercise to the following to monthly series of Industrial Product Indices for seven countries: Canada, Brazil, Belgium, Germany, Portugal, UK and USA. The data was collected at OECD data, with 504 observations. We choose Average Forecast Combination, Granger Bates Method, MCS model, Naive and Seasonal Naive Model as benchmarks.Our results suggest that MGB did not performed well. However, CvML had a lower mean absolute error for most of countries and forecast horizons, particularly at longer horizons, surpassing all the proposed benchmarks. Similar results hold for absolute mean forecast error.

Suggested Citation

  • Pinto, Jeronymo Marcondes & Marçal, Emerson Fernandes, 2019. "Cross-validation based forecasting method: a machine learning approach," Textos para discussão 498, FGV EESP - Escola de Economia de São Paulo, Fundação Getulio Vargas (Brazil).
  • Handle: RePEc:fgv:eesptd:498
    as

    Download full text from publisher

    File URL: https://repositorio.fgv.br/bitstreams/2688bba9-0f0d-4c9e-a9b2-86a8d5c29ddc/download
    Download Restriction: no
    ---><---

    References listed on IDEAS

    as
    1. Castle, Jennifer L. & Clements, Michael P. & Hendry, David F., 2015. "Robust approaches to forecasting," International Journal of Forecasting, Elsevier, vol. 31(1), pages 99-112.
    2. Barbara Rossi, 2013. "Exchange Rate Predictability," Journal of Economic Literature, American Economic Association, vol. 51(4), pages 1063-1119, December.
    3. Hsiao, Cheng & Wan, Shui Ki, 2014. "Is there an optimal forecast combination?," Journal of Econometrics, Elsevier, vol. 178(P2), pages 294-309.
    4. Graham Elliott & Allan Timmermann, 2016. "Economic Forecasting," Economics Books, Princeton University Press, edition 1, number 10740.
    5. Peter R. Hansen & Asger Lunde & James M. Nason, 2011. "The Model Confidence Set," Econometrica, Econometric Society, vol. 79(2), pages 453-497, March.
    6. Garcia, Márcio G.P. & Medeiros, Marcelo C. & Vasconcelos, Gabriel F.R., 2017. "Real-time inflation forecasting with high-dimensional models: The case of Brazil," International Journal of Forecasting, Elsevier, vol. 33(3), pages 679-693.
    7. Harding, Don & Pagan, Adrian, 2002. "Dissecting the cycle: a methodological investigation," Journal of Monetary Economics, Elsevier, vol. 49(2), pages 365-381, March.
    8. Bergmeir, Christoph & Costantini, Mauro & Benítez, José M., 2014. "On the usefulness of cross-validation for directional forecast evaluation," Computational Statistics & Data Analysis, Elsevier, vol. 76(C), pages 132-143.
    9. Gerhard Bry & Charlotte Boschan, 1971. "Programmed Selection of Cyclical Turning Points," NBER Chapters, in: Cyclical Analysis of Time Series: Selected Procedures and Computer Programs, pages 7-63, National Bureau of Economic Research, Inc.
    10. Michael P. Clements & David F. Hendry, 2001. "Forecasting Non-Stationary Economic Time Series," MIT Press Books, The MIT Press, edition 1, volume 1, number 0262531895, December.
    11. Hyndman, Rob J. & Khandakar, Yeasmin, 2008. "Automatic Time Series Forecasting: The forecast Package for R," Journal of Statistical Software, Foundation for Open Access Statistics, vol. 27(i03).
    12. Diebold, Francis X & Mariano, Roberto S, 2002. "Comparing Predictive Accuracy," Journal of Business & Economic Statistics, American Statistical Association, vol. 20(1), pages 134-144, January.
    13. Chan, Felix & Pauwels, Laurent L., 2018. "Some theoretical results on forecast combinations," International Journal of Forecasting, Elsevier, vol. 34(1), pages 64-74.
    14. Alzahrani, Naif & Neal, Peter & Spencer, Simon E.F. & McKinley, Trevelyan J. & Touloupou, Panayiota, 2018. "Model selection for time series of count data," Computational Statistics & Data Analysis, Elsevier, vol. 122(C), pages 33-44.
    15. Castle, Jennifer L. & Clements, Michael P. & Hendry, David F., 2013. "Forecasting by factors, by variables, by both or neither?," Journal of Econometrics, Elsevier, vol. 177(2), pages 305-319.
    16. Christoph Bergmeir & Rob J Hyndman & Bonsoo Koo, 2015. "A Note on the Validity of Cross-Validation for Evaluating Time Series Prediction," Monash Econometrics and Business Statistics Working Papers 10/15, Monash University, Department of Econometrics and Business Statistics.
    17. Racine, Jeff, 2000. "Consistent cross-validatory model-selection for dependent data: hv-block cross-validation," Journal of Econometrics, Elsevier, vol. 99(1), pages 39-61, November.
    Full references (including those not matched with items on IDEAS)

    Most related items

    These are the items that most often cite the same works as this one and are cited by the same works as this one.
    1. Petropoulos, Fotios & Apiletti, Daniele & Assimakopoulos, Vassilios & Babai, Mohamed Zied & Barrow, Devon K. & Ben Taieb, Souhaib & Bergmeir, Christoph & Bessa, Ricardo J. & Bijak, Jakub & Boylan, Joh, 2022. "Forecasting: theory and practice," International Journal of Forecasting, Elsevier, vol. 38(3), pages 705-871.
      • Fotios Petropoulos & Daniele Apiletti & Vassilios Assimakopoulos & Mohamed Zied Babai & Devon K. Barrow & Souhaib Ben Taieb & Christoph Bergmeir & Ricardo J. Bessa & Jakub Bijak & John E. Boylan & Jet, 2020. "Forecasting: theory and practice," Papers 2012.03854, arXiv.org, revised Jan 2022.
    2. Jeronymo Marcondes Pinto & Jennifer L. Castle, 2022. "Machine Learning Dynamic Switching Approach to Forecasting in the Presence of Structural Breaks," Journal of Business Cycle Research, Springer;Centre for International Research on Economic Tendency Surveys (CIRET), vol. 18(2), pages 129-157, July.
    3. Ricardo P. Masini & Marcelo C. Medeiros & Eduardo F. Mendes, 2023. "Machine learning advances for time series forecasting," Journal of Economic Surveys, Wiley Blackwell, vol. 37(1), pages 76-111, February.
    4. Filip Stanek, 2021. "Optimal Out-of-Sample Forecast Evaluation under Stationarity," CERGE-EI Working Papers wp712, The Center for Economic Research and Graduate Education - Economics Institute, Prague.
    5. Mei-Li Shen & Cheng-Feng Lee & Hsiou-Hsiang Liu & Po-Yin Chang & Cheng-Hong Yang, 2021. "An Effective Hybrid Approach for Forecasting Currency Exchange Rates," Sustainability, MDPI, vol. 13(5), pages 1-29, March.
    6. Gary S. Anderson & Alena Audzeyeva, 2019. "A Coherent Framework for Predicting Emerging Market Credit Spreads with Support Vector Regression," Finance and Economics Discussion Series 2019-074, Board of Governors of the Federal Reserve System (U.S.).
    7. Adusei Jumah & Robert M. Kunst, 2016. "Optimizing time-series forecasts for inflation and interest rates using simulation and model averaging," Applied Economics, Taylor & Francis Journals, vol. 48(45), pages 4366-4378, September.
    8. Nowotarski, Jakub & Weron, Rafał, 2018. "Recent advances in electricity price forecasting: A review of probabilistic forecasting," Renewable and Sustainable Energy Reviews, Elsevier, vol. 81(P1), pages 1548-1568.
    9. Drachal, Krzysztof, 2021. "Forecasting crude oil real prices with averaging time-varying VAR models," Resources Policy, Elsevier, vol. 74(C).
    10. Diebold, Francis X. & Shin, Minchul, 2019. "Machine learning for regularized survey forecast combination: Partially-egalitarian LASSO and its derivatives," International Journal of Forecasting, Elsevier, vol. 35(4), pages 1679-1691.
    11. Pierre Guérin & Danilo Leiva-Leon & Massimiliano Marcellino, 2020. "Markov-Switching Three-Pass Regression Filter," Journal of Business & Economic Statistics, Taylor & Francis Journals, vol. 38(2), pages 285-302, April.
    12. Wang, Xiaoqian & Hyndman, Rob J. & Li, Feng & Kang, Yanfei, 2023. "Forecast combinations: An over 50-year review," International Journal of Forecasting, Elsevier, vol. 39(4), pages 1518-1547.
    13. Ulrich Gunter, 2021. "Improving Hotel Room Demand Forecasts for Vienna across Hotel Classes and Forecast Horizons: Single Models and Combination Techniques Based on Encompassing Tests," Forecasting, MDPI, vol. 3(4), pages 1-36, November.
    14. Stefan Sauer & Klaus Wohlrabe, 2020. "ifo Handbuch der Konjunkturumfragen," ifo Beiträge zur Wirtschaftsforschung, ifo Institute - Leibniz Institute for Economic Research at the University of Munich, number 88.
    15. Clements, Michael P. & Franses, Philip Hans & Swanson, Norman R., 2004. "Forecasting economic and financial time-series with non-linear models," International Journal of Forecasting, Elsevier, vol. 20(2), pages 169-183.
    16. Xin Huang & Han Lin Shang & David Pitt, 2022. "A model sufficiency test using permutation entropy," Journal of Forecasting, John Wiley & Sons, Ltd., vol. 41(5), pages 1017-1036, August.
    17. Bu, Ruijun & Hizmeri, Rodrigo & Izzeldin, Marwan & Murphy, Anthony & Tsionas, Mike, 2023. "The contribution of jump signs and activity to forecasting stock price volatility," Journal of Empirical Finance, Elsevier, vol. 70(C), pages 144-164.
    18. Benjamin Poignard & Manabu Asai, 2023. "High‐dimensional sparse multivariate stochastic volatility models," Journal of Time Series Analysis, Wiley Blackwell, vol. 44(1), pages 4-22, January.
    19. Ericsson, Neil R., 2017. "How biased are U.S. government forecasts of the federal debt?," International Journal of Forecasting, Elsevier, vol. 33(2), pages 543-559.
    20. Jack Fosten, 2016. "Forecast evaluation with factor-augmented models," University of East Anglia School of Economics Working Paper Series 2016-05, School of Economics, University of East Anglia, Norwich, UK..

    More about this item

    NEP fields

    This paper has been announced in the following NEP Reports:

    Statistics

    Access and download statistics

    Corrections

    All material on this site has been provided by the respective publishers and authors. You can help correct errors and omissions. When requesting a correction, please mention this item's handle: RePEc:fgv:eesptd:498. See general information about how to correct material in RePEc.

    If you have authored this item and are not yet registered with RePEc, we encourage you to do it here. This allows to link your profile to this item. It also allows you to accept potential citations to this item that we are uncertain about.

    If CitEc recognized a bibliographic reference but did not link an item in RePEc to it, you can help with this form .

    If you know of missing items citing this one, you can help us creating those links by adding the relevant references in the same way as above, for each refering item. If you are a registered author of this item, you may also want to check the "citations" tab in your RePEc Author Service profile, as there may be some citations waiting for confirmation.

    For technical questions regarding this item, or to correct its authors, title, abstract, bibliographic or download information, contact: Núcleo de Computação da FGV EPGE (email available below). General contact details of provider: https://edirc.repec.org/data/eegvfbr.html .

    Please note that corrections may take a couple of weeks to filter through the various RePEc services.

    IDEAS is a RePEc service. RePEc uses bibliographic data supplied by the respective publishers.