Abstract
This paper considers the prediction of currency exchange rate, volatility, and momentum prediction by exploring the capabilities of Support Vector Machine (SVM) and k-Nearest Neighbor (k-NN). In this work, the parameters such as penalty C and kernel \(\gamma\) of SVM have been tuned with few optimization techniques such as random search, grid search, genetic algorithm, particle swarm optimization, ant colony optimization, firefly optimization, and BAT optimization algorithm. The final prediction has been obtained using k-NN by searching the neighborhood elements for either profit or loss. The performance of the proposed system has been tested with the Indian rupees with dollar (USD), British Pound (GBP), and Euro (EUR) for daily, weekly, and monthly in advance for prediction of currency exchange rate, volatility, and momentum in the currency market. The model BAT-SVM-k-NN has been found with the best forecasting ability based on performance measures such as mean absolute percentage error, root mean square error, mean squared forecast error, root mean squared forecast error, and mean absolute forecast error in comparison with other optimization techniques mentioned above.
Similar content being viewed by others
References
Galeshchuk S (2016) Neural networks performance in exchange rate prediction. Neurocomputing 172:446–452
Chen JH, Kuo IH (2016) The study of exchange rate variability and pressures for Asian currency unit. Asia Pac Manag Rev 21(3):1–7
Rivera RA, Rendon MV, Rodriguez-Ortiz JJ (2015) Genetic algorithms and Darwinian approaches in financial applications: a survey. Expert Syst Appl 42:7684–7697
Huang C-F, Hsu C-J, Chen C-C, Chang BR, Li C-A (2015) An intelligent model for pairs trading using genetic algorithms. Comput Intell Neurosci 501:939606
Araujo RDA, Ferreira TA (2013) A morphological-rank-linear evolutionary method for stock market prediction. Inf Sci 237:3–17
da Costa Moraes MB, Nagano MS (2014) Evolutionary models in cash management policies with multiple assets. Econ Model 39:1–7
Donate JP, Cortez P (2014) Evolutionary optimization of sparsely connected and time-lagged neural networks for time series forecasting. Appl Soft Comput 23:432–443
Hochreiter R, Wozabal D (2010) Evolutionary estimation of a coupled Markov chain credit risk model. Nat Comput Comput Finance 293:31–44
Ding Z, Granger CWJ (1996) Modelling volatility persistence of speculative returns: a new approach. J Econom 73:185–215
Ding Z, Granger CWJ, Engle RF (1993) A long memory property of stock market returns and a new model. J Empir Finance 1:83–106
Pham HT, Yang BS (2010) Estimation and forecasting of machine health condition using ARMA/GARCH model. Mech Syst Signal Process 24:546–558
Lin F, Liang D, Yeh CC, Huang JC (2014) Novel feature selection methods to financial distress prediction. Expert Syst Appl 41:2472–2483
Rojasa I, Valenzuelab O, Rojasa F, Guillena A, Herreraa LJ, Pomaresa H, Arquezb L, Pasadas M (2008) Soft-computing techniques and ARMA model for time series prediction. Neurocomputing 71:519–537
Anastasakis L, Mort N (2009) Exchange rate forecasting using a combined parametric and nonparametric self-organising modelling approach. Expert Syst Appl 36:12001–12011
Babu BV, Munawar SA (2007) Differential evolution strategies for optimal design of shell-and-tube heat exchangers. Chem Eng Sci 62(14):2739–3720
Chattopadhyay S, Jhajharia D, Chattopadhyay G (2011) Trend estimation and univariate forecast of the sunspot numbers: development and comparison of ARMA, ARIMA and autoregressive neural network models. Comptes Rendus Geosci 343:433–442
Majhi R, Majhi B, Rout M, Mishra S, Panda G (2009) Efficient sales forecasting using ARMA-PSO model. In: IEEE international conference on nature and biologically inspired, computing, pp 1333–1337
Zhang Y-Q, Wan X (2007) Statistical fuzzy interval neural networks for currency exchange rate time series prediction. Appl Soft Comput 7(4):1149–1156
Önder E, Fırat B, Hepsen A (2013) Forecasting macroeconomic variables using artificial neural network and traditional smoothing techniques. Appl Finance Bank 3(4):3–104
Santos A, da Costa N, dos Santos L (2007) Coelho, Computational intelligence approaches and linear models in case studies of forecasting exchange rates. Expert Syst Appl 33(4):816–823
Gradojevic N, Erdemlioglu D, Gençay R (2017) Informativeness of trade size in foreign exchange markets. Econ Lett 150:27–33
Evans C, Pappas K, Xhafa F (2013) Utilizing artificial neural networks and genetic algorithms to build an algo-trading model for intra-day foreign exchange speculation. Math Comput Model 58:1249–1266
Rehman M, Khan GM, Mahmud SA (2014) Foreign currency exchange rate prediction using CGP and recurrent neural network. Int Conf Future Inf Eng IERI Pocedia 10:239–244
Rout M, Majhi B, Majhi R, Panda G (2014) Forecasting of currency exchange rates using an adaptive ARMA model with differential evolution based training. J King Saud Univ Comput Inf Sci 26:7–18
Gençay R, Gradojevic N, Olsen R, Selçuk F (2015) Informed traders’ arrival in foreign exchange markets: does geography matter? Empir Econ 49(4):1431–1462
Gençay R, Gradojevic N (2013) Private information and its origins in an electronic foreign exchange market. Econ Model 33:86–93
Gradojevic N, Gençay R (2013) Fuzzy logic, trading uncertainty and technical trading. J Bank Finance 37(2):578–586
Xue Y, Gençay R (2012) Trading frequency and volatility clustering. J Bank Finance 36(3):760–773
Gençay R, Gradojevic N, Selçuk F, Whitcher B (2010) Asymmetry of information flow between volatilities across time scales. Quant Finance 10(8):895–915
Gençay R, Gradojevic N (2010) Crash of’87—Was it expected?: aggregate market fears and long-range dependence. J Empir Finance 17(2):270–282
Gençay R, Dacorogna MM, Ballocchi G, Olsen RB, Pictet O (2002) Real-time trading models and the statistical properties of foreign exchange rates (December 1998). Olsen and Associates Working Paper No. 319. doi: 10.2139/ssrn.155048. Available at SSRN: https://ssrn.com/abstract=155048
Gencay R, Dacorogna M, Olsen R, Pictet O (2003) Foreign exchange trading models and market behavior. J Econ Dyn Control 27(6):909–935
Xu Z, Gençay R (2003) Scaling, self-similarity and multifractality in FX markets. Physica A 323:578–590
Nekhili R, Altay-Salih A, Gençay R (2002) Exploring exchange rate returns at different time horizons. Physica A 313(3):671–682
Dacorogna MM, Gençay R, Müller UA, Pictet OV (2001) Effective return, risk aversion and drawdowns. Physica A 289(1):229–248
Gençay R, Selçuk F, Whitcher B (2001) Scaling properties of foreign exchange volatility. Physica A 289(1):249–266
Arifovic J, Gencay R (2000) Statistical properties of genetic learning in a model of exchange rate. J Econ Dyn Control 24(5):981–1005
Gencay R (1999) Linear, non-linear and essential foreign exchange rate prediction with simple technical trading rules. J Int Econ 47(1):91–107
Gencay R, Stengos T (1998) Moving average rules, volume and the predictability of security returns with feedforward networks. J Forecast 17:401–414
Gencay R (1998) The predictability of security returns with simple technical trading rules. J Empir Finance 5(4):347–359
Gencay R (1998) Optimization of technical trading strategies and the profitability in security markets. Econ Lett 59(2):249–254
Gençay R, Liu T (1997) Nonlinear modelling and prediction with feedforward and recurrent networks. Physica D 108(1–2):119–134
Gencay R, Stengos T (1997) Technical trading rules and the size of the risk premium in security returns. Stud Nonlinear Dyn Econ 2(2). doi:10.2202/1558-3708.1026
Gencay R (1996) Non-linear prediction of security returns with moving average rules. J Forecast 15(3):165–174
Flores JJ, Graff M, Rodriguez H (2012) Evaluative design of ARMA and ANN models for time series forecasting. Renew Energy 44:225–230
Majhi R, Panda G, Sahoo G (2009) Efficient prediction of exchange rates with low complexity artificial neural network models. Expert Syst Appl 36:181–189
Chen A-S, Leung MT (2004) Regression neural network for error correction in foreign exchange forecasting and trading. Comput Oper Res 31:1049–1068
Ozkan F (2012) A comparison of the monetary model and artificial neural networks in exchange rate forecasting bus. Econ Res J 3(1):27–39
Bissoondeeal RK, Karoglou M, Gazely AM (2011) Forecasting the UK/US exchange rate with divisia monetary models and neural networks. Scott J Polit Econ 58(1):127–152
Chen A, Leung MT, Daouk H (2003) Applications of neural networks to an emerging financial market: forecasting and trading the Taiwan stock index. Comput Oper Res 30:901–923
Huang S-C (2008) Online option price forecasting by using unscented Kalman filters and support vector machines. Expert Syst Appl 34:2819–2825
Burges CJC (1998) A tutorial on support vector machines for pattern classification. Data Min Knowl Disc 2(2):121–167
Chapelle O, Vapnik V, Bousquet O, Mukherjee S (2002) Choosing multiple parameters for support vector machines. Mach Learn 46(13):131–159
Collobert R, Bengio S (2001) Svmtorch: support vector machines for large scale regression problems. J Mach Learn Res 1:143–160
Lee YJ, Mangasarian OL (2001) RSVM: reduced support vector machines. In: CD proceedings of the first SIAM international conference on data mining
Scholkopf B, Smola AJ (2002) Learning with kernels: support vector machines, regularization, optimization, and beyond. The MIT Press, Cambridge
Trafalis TB, Ince H, Mishina T (2003) Support vector regression in option pricing. In: Proceedings of conference on computational intelligence and financial engineering (CIFer), Hong Kong
Nag AK, Mitra A (2002) Forecasting daily foreign exchange rates using genetically optimized neural networks. J Forecast 21:501–551
Cortes C, Vapnik V (1995) Support vector networks. Mach Learn 20:273–297
Vapnik V (1995) The nature of statistical learning theory. Springer, Berlin
Fayek MB (2013) Multi-objective optimization of technical stock market indicators using gas. Int J Comput Appl 68(20):0975–8887
Thomsett MC (2009) The options trading body of knowledge: the definitive source for information. FT Press, Upper Saddle River, p 268
Blau W (1991) True strength index. Tech Anal Stocks Commod (traders.com) 11(1):438–446
Murphy JJ (2009) The visual investor: how to spot market trends, 2nd edn. Wiley, New York, p 100
http://stockcharts.com/school/doku.php?id=chart_school:technical_indicators:williams_r
Zhang GP, Qi M (2005) Neural network forecasting for seasonal and trend time series. Eur J Oper Res 160(2):501–514
Nayak RK, Mishra D, Rath AK (2015) A Naïve SVM-K-NN based stock market trend reversal analysis for Indian benchmark indices. Appl Soft Comput 35:670–680
Cha S-H (2007) Comprehensive survey on distance/similarity measures between probability density functions. City 1(2):1
Coope ID, Christopher JP (2001) On the convergence of grid-based methods for unconstrained optimization. SIAM J Optim 11(4):859–869
Bergstra J, Bengio Y (2012) Random search for hyper-parameter optimization. J Mach Learn Res 13(1):281–305
Ning HH (2010) Short term forecasting of stock price based on genetic neural network. In: Sixth international conference on natural computation, pp 1838–1841
Eberhart RC, Kennedy J (1995) A new optimizer using particle swarm theory. In: Proceedings of the sixth international symposium on micro machine and human science, vol 1, pp 39–43
Chakravarty S, Dash PK (2012) A PSO based integrated functional link net and interval type-2 fuzzy logic system for predicting stock market indices. Appl Soft Comput 12:931–941
Dorigo M, Stützle T (2009) Ant colony optimization: overview and recent advances. In: Techreport, IRIDIA, Universite Libre de Bruxelles
Yang X-S (2009) Firefly algorithms for multimodal optimization, stochastic algorithms: foundations and applications. Springer, Berlin Heidelberg, pp 169–178
Yang X-S (2010) A new metaheuristic bat-inspired algorithm, nature inspired cooperative strategies for optimization (NICSO). Springer, Berlin, pp 65–74
Schmitt LM (2001) Theory of genetic algorithms. Theor Comput Sci 259(1):1–61
Houck CR, Joines J, Kay MG (1995) A genetic algorithm for function optimization: a Matlab implementation. NCSU-IE TR 95(09):1–10
Wu CH, Tzeng GH, Goo YJ, Fang WC (2007) A real-valued genetic algorithm to optimize the parameters of support vector machine for predicting bankruptcy. Expert Syst Appl 32(2):397–408
Author information
Authors and Affiliations
Corresponding author
Ethics declarations
Conflict of interest
I certify that there is no actual or potential conflict of interest in relation to this article.
Rights and permissions
About this article
Cite this article
Nayak, R.K., Mishra, D. & Rath, A.K. An optimized SVM-k-NN currency exchange forecasting model for Indian currency market. Neural Comput & Applic 31, 2995–3021 (2019). https://doi.org/10.1007/s00521-017-3248-5
Received:
Accepted:
Published:
Issue Date:
DOI: https://doi.org/10.1007/s00521-017-3248-5