Price predicting with LSTM artificial neural network and portfolio selection model of financial assets and digital currencies
Subject Areas : Financial engineeringFaranak Khonsarian 1 , Babak teimourpour 2 , Mohammad Ali Rastegar 3
1 - Department of Information Technology Engineering, Faculty of Industrial and Systems Engineering, Tarbiat Modares University, Tehran, Iran
2 - Department of Information Technology Engineering, Faculty of Industrial and Systems Engineering, Tarbiat Modares University, Tehran, Iran
3 - Financial Engineering Group, Industrial & Systems Engineering, Tarbiat Modares University, Tehran, Iran
Keywords: Portfolio, Financial Assets, Digital currency, Price prediction, LSTM neural network,
Abstract :
Finding solutions for price prediction, forming an optimal portfolio and achieving more profit are the basic goals of financial market activists. The purpose of this research is to predict the price of financial assets such as several stocks, gold, coin and a number of digital currencies using the LSTM neural network model and then form an optimal portfolio by calculating the rate of return, risk and the Sharpe ratio. The data used is from the archives of the Tehran Stock Exchange website, the website of the gold, coin and currency information network, as well as the website of buying and selling digital currencies. The time series of the prices of the investigated assets is between 2017 and 2020. Also, we used Python programming language and Gephi software to build the model and analyze the data. In the end, it was found that the LSTM neural network model is capable of predicting the price of financial assets with a very low error rate in each asset, and according to the Sharpe ratio obtained for each financial asset and the correlation matrix, Vebank stock, Khbahman 1 stock, and Digital currencies TRON, Tether and Bitcoin allocate more shares in the proposed portfolio.
_|1) اسکندری، مهدی، سعیدی، علی، فلاح، میرفیض. (1398). بررسی نقش طلا در تنوعبخشی سبد سرمایهگذاری در سهام. چشم انداز مدیریت مالی، 9(27)، 81-107.
2) سعیدی، علی، واحدی، نرگس. (1392). مقایسة ریسک و بازده صندوق ها و شرکت¬های سرمایه-گذاری در بورس اوراق بهادار تهران. فصلنامه بورس اوراق بهادار،6(22)، 121-138.
3) سهرابی، مریم، میربرگ کار، سید مظفر، چیرانی، ابراهیم، خردیار، سینا. (1401). مدلسازی پیشبینی جهشهای شاخص بازار سهام بر اساس رویکرد شبکه عصبی بازگشتی یادگیری عمیق. فصلنامه بورس اوراق بهادار، 15(59)، 161-180.
4) شکری، نعیم، سحاب خدامرادی، مرتضی، حاجیلو مقدم، امیرحسین (1400). بررسی اثرات سرریز نوسانات مالی میان ارزهای دیجیتالی (کاربرد رهیافت گارچ چند متغیره ((BEKK- GARCH) چشم انداز مدیریت مالی،11(35)، 143-172.
5) شهرستانی، حمید، بیدآبادی، بیژن و ثوابی اصل، فرهاد. (1389). توسعه نظریه مارکوویتز شارپ و مرزکارای جدید مطالعه موردی: شرکت¬های سیمانی بورس تهران. پژوهش¬های رشد و توسعه پایدار (پژوهش¬های اقتصادی)، 10(2)، 43-60. SID. https://sid.ir/paper/86602/fa
6) Azari, A. (2019). Bitcoin price prediction: An ARIMA approach. arXiv preprint arXiv:. 190405315.
7) Chaweewanchon, A., & Chaysiri, R. (2022). Markowitz Mean-Variance Portfolio Optimization with Predictive Stock Selection Using Machine Learning. International Journal of Financial Studies, 10(3). https://doi.org/10.3390/ijfs10030064
8) Chen, Z., Li, H., Li, Z., Yin, L., & Carey, W. P. (2022). Analysis of Ten Stock Portfolios Using Markowitz and Single Index Models.
9) Ho, M. K., Darman, H. and Musa, S. (2021) ‘Stock Price Prediction Using ARIMA, Neural Network and LSTM Models’, Journal of Physics: Conference Series, 1988(1). doi: 10.1088/1742-6596/1988/1/012041.
10) Liu, W. (2019). Portfolio diversification across cryptocurrencies. Finance Research Letters, 29, 200-205.
11) Li, Y., Luo, Y., & Zhou, Y. (2021). Empirical Analysis of Optimal Stock Portfolio under the Background of COVID-19. E3S Web of Conferences, 235. https://doi.org/10.1051/e3sconf/202123501027
12) Mallikarjuna, M., Rao, R. P. (2019) ‘Evaluation of forecasting methods from selected stock market returns’, Financial Innovation. Financial Innovation, 5(1). doi: 10.1186/s40854-019-0157-x.
13) McNally, S., Roche, J., & Caton, S. (2018, March). Predicting the price of bitcoin using machine learning. In 2018 26th euromicro international conference on parallel, distributed and network-based processing (PDP) (pp. 339-343). IEEE.
14) Sarvaiya, D., Ramchandani, D. (2022). Time Series Analysis and Forecasting of Gold Price using ARIMA and LSTM Model. International Journal for Research in Applied Science & Engineering Technology. Volume 10 Issue IX Sep 2022.
15) Saxena, A., Sukumar, T. R., Nadu, T. (2018). Predicting bitcoin price using LSTM and compare its predictability with ARIMA model. International Journal of Pure and Applied Mathematics, 119(17), 2591-2600.
16) Situmorang, R. E., Maruddani, D. A. I., & Santoso, R. (2019). Formation of stock portfolio using Markowitz method and measurement of Value at Risk based on generalized extreme value (Case study: Company’s stock the IDX Top Ten Blue 2017, Period 2 January-29 December 2017). Journal of Physics: Conference Series, 1217(1). https://doi.org/10.1088/1742-6596/1217/1/012084
17) Hubrich, S. (2022). Bitcoin in a Multi-Asset Portfolio.The Journal of Alternative Investments Nov 2022, jai.2022.1.177; DOI: 10.3905/jai.2022.1.177
18) Vasiani, V. D., Handari, B. D., & Hertono1, G., F. (2020). Stock portfolio optimization using priority index and genetic algorithm. J. Phys.: Conf. Ser. 1442 012031 DOI 10.1088/1742-6596/1442/1/012031
19) Vijh, M., Chandola, D., Tikkiwal, V. A., & Kumar, A. (2020). Stock Closing Price Prediction using Machine Learning Techniques. Procedia Computer Science, 167, 599–606. https://doi.org/10.1016/j.procs.2020.03.326
20) Wu, C. H., Lu, C. C., Ma, Y. F., & Lu, R. S. (2018, November). A new forecasting framework for bitcoin price with LSTM. In 2018 IEEE International Conference on Data Mining Workshops (ICDMW) (pp. 168-175). IEEE.
21) Xiao, R. et al. (2022) ‘Predict stock prices with ARIMA and LSTM’, pp. 1–14. Available at: http://arxiv.org/abs/2209.02407.
22) Zanc, R., Cioara, T., & Anghel, I. (2019). "Forecasting Financial Markets using Deep Learning,".IEEE 15th International Conference on Intelligent Computer Communication and Processing (ICCP), Cluj-Napoca, Romania, 2019, pp. 459-466, doi: 10.1109/ICCP48234.2019.8959715.
|_