In collaboration with Payame Noor University and the Iranian Society of Instrumentation and Control Engineers

Document Type : Applied Article

Authors

Department of Applied Mathematics, Faculty of Mathematical Sciences, Ferdowsi University of Mashhad, Mashhad, Iran

Abstract

As the Forex market becomes increasingly complex, accurate directional forecasting is essential for effective trading decisions. This study proposes a multi-timeframe framework to evaluate directional trend prediction for the EUR/USD exchange rate using Ichimoku Cloud-inspired feature engineering and CNN-based hybrid architectures, including CNN, CNN-LSTM, and CNN-GRU. The study optimizes model hyperparameters using the Starfish Optimization Algorithm (SFOA). Specifically, the study investigates multi-step trend prediction for the H1 and H4 timeframes, and one-step-ahead prediction for the daily (D1) timeframe. Historical EUR/USD data are used to train continuous forecasting models, whose outputs are transformed into discrete trend classification labels. The framework ultimately employs a voting mechanism to determine the final trend decision at the daily (D1) timeframe. To assess the model's zero-shot classification capability and generalization, eight additional currency pairs are evaluated using the same evaluation criteria at the relevant stages to assess both individual model performance and overall framework effectiveness. Regression performance is assessed using MSE, MAE, and MAPE, while classification performance is evaluated using Accuracy and F1-score. Statistical robustness is further examined using the Diebold--Mariano test and bootstrap analysis. Experimental results demonstrate that incorporating GRU layers into CNN architectures consistently improves forecasting performance across multiple timeframes and currency pairs, with the proposed IICGS architecture achieving the most competitive overall performance. Selected results and implementation code are publicly available on GitHub.

Highlights

  • A multi-timeframe CNN-LSTM/CNN-GRU framework predicts EUR/USD directional trends.
  • Ichimoku-inspired features boost trend prediction without future data leakage.
  • Starfish Optimization Algorithm outperforms GA, PSO, and GWO in tuning.
  • Holm-Bonferroni-adjusted DM tests and bootstrap confirm statistical robustness.
  • Zero-shot tests on eight unseen currency pairs show strong generalization.

Keywords

Main Subjects

[1] Ayitey Junior, M., Appiahene, P., Appiah, O., Bombie, C. N. (2023). “Forex market forecasting using machine learning: Systematic Literature Review and meta-analysis”. Journal of Big Data, 10(1), 9. https://doi.org/10.1186/s40537-022-00676-2
[2] Bank for International Settlements. (2019). “Triennial Central Bank Survey of foreign exchange and OTC derivatives markets in 2019: Foreign exchange turnover in April 2019”. Bank for International Settlements. https://www.bis.org/statistics/rpfx19_fx. pdf
[3] Bank for International Settlements. (2022). “Triennial Central Bank Survey of foreign exchange and over-the-counter (OTC) derivatives markets in 2022”. Bank for International Settlements. https://www.bis.org/statistics/rpfx22_fx.pdf.
[4] Cho, K., Van Merriënboer, B., Gulçehre, Ç., Bahdanau, D., Bougares, F., Schwenk, H., & Bengio, Y. (2014). “Learning phrase representations using RNN encoder–decoder for statistical machine translation”. Proceedings of the 2014 Conference on Empirical Methods in Natural Language Processing (EMNLP), 1724–1734. https://doi.org/10.3115/ v1/D14-1179
[5] Deng, S., Xiao, C., Zhu, Y., Peng, J., Li, J., Liu, Z. (2023). “High-frequency direction forecasting and simulation trading of the crude oil futures using Ichimoku KinkoHyo and Fuzzy Rough Set”. Expert Systems with Applications, 215, 119326. https://doi.org/ 10.1016/j.eswa.2022.119326
[6] Diebold, F. X., Mariano, R. S. (2002). “Comparing predictive accuracy”. Journal of Business & Economic Statistics, 20(1), 134–144. https://doi.org/10.1198/ 073500102753410444
[7] Dodge, Y. (Ed.). (2003). “The Oxford dictionary of statistical terms”. Oxford University Press.
[8] Elliott, N. (2007). “Ichimoku charts: An introduction to Ichimoku Kinko clouds”. Harriman House Limited.
[9] Gauss, C. F. (2011). “Theoria motus corporum coelestium in sectionibus conicis solem ambientium (Vol. 7)”. Cambridge: Cambridge University Press. https://doi.org/10.1017/CBO9780511841705
[10] Goodfellow, I., Bengio, Y., Courville, A. (2016). “Deep learning”. MIT Press.
[11] Gülmez, B. (2023). “Stock price prediction with optimized deep LSTM network with artificial rabbits optimization algorithm”. Expert Systems with Applications, 227, 120346. https://doi.org/10.1016/j.eswa.2023.120346
[12] Hochreiter, S., Schmidhuber, J. (1997). “Long short-term memory”. Neural Computation, 9(8), 1735–1780. https://doi.org/10.1162/neco.1997.9.8.1735
[13] Hoffmann, J., Navarro, O., Kastner, F., Janßen, B., Hubner, M. (2017). “A survey on CNN and RNN implementations”. In PESARO 2017: The Seventh International Conference on Performance, Safety and Robustness in Complex Systems and Applications.
[14] Holm, S. (1979). “A simple sequentially rejective multiple test procedure”. Scandinavian journal of statistics, 65-70.
[15] Islam, M. S., Hossain, E. (2021). “Foreign exchange currency rate prediction using a GRU-LSTM hybrid network”. Soft Computing Letters, 3, 100009. https://doi.org/ 10.1016/j.socl.2020.100009
[16] Jarusek, R., Volna, E., Kotyrba, M. (2022). “FOREX rate prediction improved by Elliott waves patterns based on neural networks”. Neural Networks, 145, 342-355. https:// doi.org/10.1016/j.neunet.2021.10.024
[17] Khaldi, R., El Afia, A., Chiheb, R., Tabik, S. (2023). “What is the best RNN-cell structure to forecast each time series behavior?”. Expert Systems with Applications, 215, 119140. https://doi.org/10.1016/j.eswa.2022.119140
[18] Khattak, B. H. A., Shafi, I., Rashid, C. H., Safran, M., Alfarhood, S., Ashraf, I. (2024). “Profitability trend prediction in crypto financial markets using Fibonacci technical indicator and hybrid CNN model”. Journal of Big Data, 11(1), 58. https://doi.org/10. 1186/s40537-024-00908-7
[19] Kim, J., Oh, S., Kim, H., Choi, W. (2023). “Tutorial on time series prediction using 1DCNN and BiLSTM: A case example of peak electricity demand and system marginal price prediction”. Engineering Applications of Artificial Intelligence, 126, 106817. https://doi.org/10.1016/j.engappai.2023.106817
[20] Künsch, H. R. (1989). “The jackknife and the bootstrap for general stationary observations”. In The Annals of Statistics, 1217-1241. https://doi.org/10.1214/aos/1176347265
[21] Lawal, A., Rehman, S., Alhems, L. M., Alam, M. M. (2021). “Wind speed prediction using hybrid 1D CNN and BLSTM network”. IEEE Access, 9, 156672–156679. https: //doi.org/10.1109/ACCESS.2021.3129883
[22] LeCun, Y., Bottou, L., Bengio, Y., Haffner, P. (2002). “Gradient-based learning applied to document recognition”. Proceedings of the IEEE, 86(11), 2278–2324. https://doi. org/10.1109/5.726791
[23] Li, Z., Liu, F., Yang, W., Peng, S., Zhou, J. (2021). “A survey of convolutional neural networks: Analysis, applications, and prospects”. IEEE transactions on neural networks and learning systems, 33(12), 6999-7019. https://doi.org/10.1109/TNNLS.2021. 3084827
[24] Lim, M. A. (2015). “The handbook of technical analysis+ test bank: The practitioner’s comprehensive guide to technical analysis”. John Wiley & Sons.
[25] Mabrouk, N., Chihab, M., Hachkar, Z., Chihab, Y. (2022). “Intraday trading strategy based on gated recurrent unit and convolutional neural network: Forecasting daily price direction”. International Journal of Advanced Computer Science and Applications, 13(3). https://doi.org/10.14569/IJACSA.2022.0130369
[26] Makridakis, S., Wheelwright, S. C., Hyndman, R. J. (2008). “Forecasting methods and applications”. John Wiley & Sons.
[27] Mirzajani, S., Roohi, M. (2026). “Feedback long short-term memory: A long short-term memory-based framework for multivariate time series prediction in chaotic systems”. Control and Optimization in Applied Mathematics, 11(1), 199–218. https://doi.org/10.30473/coam.2025.72730.1312
[28] Özorhan, M. O., Toroslu, İ. H., Şehitoğlu, O. T. (2019). “Short-term trend prediction in financial time series data”. Knowledge and Information Systems, 61(1), 397-429. https: //doi.org/10.1007/s10115-018-1303-x
[29] Sevastjanov, P., Kaczmarek, K., Rutkowski, L. (2024). “A multi-model approach to the development of algorithmic trading systems for the Forex market”. Expert Systems with Applications, 236, 121310. https://doi.org/10.1016/j.eswa.2023.121310
[30] Sokolova, M., Lapalme, G. (2009). “A systematic analysis of performance measures for classification tasks”. Information Processing & Management, 45(4), 427-437. https:// doi.org/10.1016/j.ipm.2009.03.002
[31] Zhong, C., Li, G., Meng, Z., Li, H., Yildiz, A. R., Mirjalili, S. (2025). “Starfish optimization algorithm (SFOA): A bio-inspired metaheuristic algorithm for global optimization compared with 100 optimizers”. Neural Computing and Applications, 37(5), 3641-3683. https://doi.org/10.1007/s00521-024-10694-1