Research article

Cryptocurrency price prediction and portfolio optimization based on LSTM and multi-task neural network

  • Published: 08 September 2025
  • JEL Codes: G11, G17, C51, C58

  • The precise forecast of cryptocurrency prices is essential for portfolio investment because of their volatility and operability in virtual trading markets, which poses a huge trouble to investors' decision-making ability and investment planning. In this paper, we concentrated on the prediction of the recent trends of mainstream cryptocurrencies and selected them to optimize the portfolio to maximize profit and reduce risk. We used neural networks to solve this problem, which has three layers, including the LSTM layer, dropout layer, and dense layer. We focused on BCH, BTC, ETH, ETC, LTC, EOS, and XRP and collected their datasets for estimations. An LSTM model, a multi-task learning model, and a novel loss function, where the Negative Sharpe Ratio is provided, were implemented to predict the best portfolio (weights) for the cryptocurrencies mentioned above. The common evaluation indices, such as MSE, RMSE, MAE, and R-square ($ {R}^{2} $), can demonstrate the accuracy and reliability of the Neural Network models. Due to the significant price differences among currencies, the values of MSE, MSE, and MAE were large, making it difficult to evaluate their accuracy. Therefore, $ {R}^{2} $ was adopted. Finally, we simulated the portfolio investment and saw the revenue compared to the existing approaches. The new machine learning model abandoned the previous methods, which only predicted and analyzed a single cryptocurrency and ignored the correlations among them. Therefore, our innovation of this research was to use neural networks to consider investment plans combining multiple currencies while minimizing volatility and ensuring a large Sharpe Ratio, thereby obtaining the best portfolio investment of cryptocurrencies.

    Citation: Weiqi Chen, Hang Zheng. Cryptocurrency price prediction and portfolio optimization based on LSTM and multi-task neural network[J]. Quantitative Finance and Economics, 2025, 9(3): 658-681. doi: 10.3934/QFE.2025023

    Related Papers:

  • The precise forecast of cryptocurrency prices is essential for portfolio investment because of their volatility and operability in virtual trading markets, which poses a huge trouble to investors' decision-making ability and investment planning. In this paper, we concentrated on the prediction of the recent trends of mainstream cryptocurrencies and selected them to optimize the portfolio to maximize profit and reduce risk. We used neural networks to solve this problem, which has three layers, including the LSTM layer, dropout layer, and dense layer. We focused on BCH, BTC, ETH, ETC, LTC, EOS, and XRP and collected their datasets for estimations. An LSTM model, a multi-task learning model, and a novel loss function, where the Negative Sharpe Ratio is provided, were implemented to predict the best portfolio (weights) for the cryptocurrencies mentioned above. The common evaluation indices, such as MSE, RMSE, MAE, and R-square ($ {R}^{2} $), can demonstrate the accuracy and reliability of the Neural Network models. Due to the significant price differences among currencies, the values of MSE, MSE, and MAE were large, making it difficult to evaluate their accuracy. Therefore, $ {R}^{2} $ was adopted. Finally, we simulated the portfolio investment and saw the revenue compared to the existing approaches. The new machine learning model abandoned the previous methods, which only predicted and analyzed a single cryptocurrency and ignored the correlations among them. Therefore, our innovation of this research was to use neural networks to consider investment plans combining multiple currencies while minimizing volatility and ensuring a large Sharpe Ratio, thereby obtaining the best portfolio investment of cryptocurrencies.



    加载中


    [1] Abu Bakar N, Rosbi S, Uzaki K (2019) Forecasting Cryptocurrency Price Movement Using Moving Average Method: A Case Study of Bitcoin Cash. Int J Adv Res 7: 609–614. https://doi.org/10.21474/ijar01/10188 doi: 10.21474/ijar01/10188
    [2] Alahmari SA (2019) Using Machine Learning ARIMA to Predict the Price of Cryptocurrencies. ISeCure 11: 139–144. https://doi.org/10.22042/isecure.2019.11.0.18 doi: 10.22042/isecure.2019.11.0.18
    [3] Angela O, Sun Y (2020) Factors affecting Cryptocurrency Prices: Evidence from Ethereum. IEEE Xplore, 318–323. https://doi.org/10.1109/ICIMTech50083.2020.9211195 doi: 10.1109/ICIMTech50083.2020.9211195
    [4] Bollerslev T (2008) Glossary to ARCH (GARCH). SSRN Electron J. https://doi.org/10.2139/ssrn.1263250 doi: 10.2139/ssrn.1263250
    [5] Cohen G (2022) Trading cryptocurrencies using algorithmic average true range systems. J Forecasting 42: 212–222. https://doi.org/10.1002/for.2906 doi: 10.1002/for.2906
    [6] Corbet S, Lucey B, Urquhart A, et al. (2019) Cryptocurrencies as a financial asset: A systematic analysis. Int Rev Financ Anal 62: 182–199. https://doi.org/10.1016/j.irfa.2018.09.003 doi: 10.1016/j.irfa.2018.09.003
    [7] Fabozzi FJ, Markowitz HM, Kolm PN, et al. (2011) Portfolio Selection, In: Frank J. Fabozzi, Harry M. Markowitz, The Theory and Practice of Investment Management: Asset Allocation, Valuation, Portfolio Construction, and Strategies, Second Edition, 45–78. https://doi.org/10.1002/9781118267028.ch3
    [8] Ferland R, Latour A, Oraichi D (2006) Integer-Valued GARCH Process. J Time Series Anal 27: 923–942. https://doi.org/10.1111/j.1467-9892.2006.00496.x doi: 10.1111/j.1467-9892.2006.00496.x
    [9] García-Medina A, Aguayo-Moreno E (2024) LSTM–GARCH Hybrid Model for the Prediction of Volatility in Cryptocurrency Portfolios. Computat Econ 63: 1511–1542. https://doi.org/10.1007/s10614-023-10373-8 doi: 10.1007/s10614-023-10373-8
    [10] García-Medina A, Luu Duc Huynh T (2021) What Drives Bitcoin? An Approach from Continuous Local Transfer Entropy and Deep Learning Classification Models. Entropy 23: 1582. https://doi.org/10.3390/e23121582 doi: 10.3390/e23121582
    [11] Golnari A, Komeili MH, Azizi Z (2024) Probabilistic deep learning and transfer learning for robust cryptocurrency price prediction. Expert Syst Appl 255: 124404. https://doi.org/10.1016/j.eswa.2024.124404 doi: 10.1016/j.eswa.2024.124404
    [12] Ji S, Kim J, Im H (2019) A Comparative Study of Bitcoin Price Prediction Using Deep Learning. Mathematics 7: 898. https://doi.org/10.3390/math7100898 doi: 10.3390/math7100898
    [13] Khedr AM, Arif I, El-Bannany M, et al. (2021) Cryptocurrency price prediction using traditional statistical and machine-learning techniques: A survey. Intell Syst Account Financ Manage 28: 3–34. https://doi.org/10.1002/isaf.1488 doi: 10.1002/isaf.1488
    [14] Kwon DH, Kim JB, Heo JS, et al. (2019) Time Series Classification of Cryptocurrency Price Trend Based on a Recurrent LSTM Neural Network. J Inf Process Syst 15: 694–706. https://doi.org/10.3745/JIPS.03.0120 doi: 10.3745/JIPS.03.0120
    [15] Liu W (2018) Portfolio diversification across cryptocurrencies. Financ Res Lett 29: 200–205. https://doi.org/10.1016/j.frl.2018.07.010 doi: 10.1016/j.frl.2018.07.010
    [16] Ma Y, Ahmad F, Liu M, et al. (2020) Portfolio optimization in the era of digital financialization using cryptocurrencies. Technol Forecast Soc 161: 120265. https://doi.org/10.1016/j.techfore.2020.120265 doi: 10.1016/j.techfore.2020.120265
    [17] Malsa N, Vyas V, Gautam J (2021) RMSE calculation of LSTM models for predicting prices of different cryptocurrencies. Int J Syst Assur Eng Manage, 1–9. https://doi.org/10.1007/s13198-021-01431-1
    [18] Markowitz H, Todd GP (2025) Mean-Variance Analysis in Portfolio Choice and Capital Markets, John Wiley & Sons. Available from: https://books.google.com.hk/books?hl = zh-CN & lr = & id = eJ8QUsgfZ8wC & oi = fnd & pg = PR9 & dq = mean-variance & ots = t7tXVk4iex & sig = B7byDsUcFA1zhGjcrtquA6y2asU & redir_esc = y#v = onepage & q = mean-variance & f = false.
    [19] Patel MM, Tanwar S, Gupta R, et al. (2020) A Deep Learning-based Cryptocurrency Price Prediction Scheme for Financial Institutions. J Inf Secur Appl 55: 102583. https://doi.org/10.1016/j.jisa.2020.102583 doi: 10.1016/j.jisa.2020.102583
    [20] Petukhina A, Trimborn S, Härdle WK, et al. (2021) Investing with cryptocurrencies – evaluating their potential for portfolio allocation strategies. Quant Financ 21: 1–29. https://doi.org/10.1080/14697688.2021.1880023 doi: 10.1080/14697688.2021.1880023
    [21] Ruder S (2017) An Overview of Multi-Task Learning in Deep Neural Networks. arXiv (Cornell University). https://doi.org/10.48550/arXiv.1706.05098
    [22] Sharpe WF (1964) Capital Asset Prices: A Theory of Market Equilibrium Under Conditions of Risk. J Financ 19: 425–442. https://doi.org/10.1111/j.1540-6261.1964.tb02865.x doi: 10.1111/j.1540-6261.1964.tb02865.x
    [23] Wen NS, Ling LS (2023) Evaluation of Cryptocurrency Price Prediction Using LSTM and CNNs Models. JOIV Int J Inf Visual 7: 2016–2016. https://doi.org/10.30630/joiv.7.3-2.2344 doi: 10.30630/joiv.7.3-2.2344
    [24] Wu CH, Lu CC, Ma YF, et al. (2018) A New Forecasting Framework for Bitcoin Price with LSTM. IEEE Xplore. https://doi.org/10.1109/ICDMW.2018.00032
    [25] Zhang Z, Zohren S, Roberts S (2020) Deep Reinforcement Learning for Trading. J Financ Data Sci 2: 25–40. https://doi.org/10.3905/jfds.2020.1.030 doi: 10.3905/jfds.2020.1.030
    [26] Zhao D, Rinaldo A, Brookins C (2019) Cryptocurrency Price Prediction and Trading Strategies Using Support Vector Machines. arXiv.org. https://doi.org/10.48550/arXiv.1911.11819
  • Reader Comments
  • © 2025 the Author(s), licensee AIMS Press. This is an open access article distributed under the terms of the Creative Commons Attribution License (http://creativecommons.org/licenses/by/4.0)
通讯作者: 陈斌, bchen63@163.com
  • 1. 

    沈阳化工大学材料科学与工程学院 沈阳 110142

  1. 本站搜索
  2. 百度学术搜索
  3. 万方数据库搜索
  4. CNKI搜索

Metrics

Article views(1850) PDF downloads(108) Cited by(0)

Article outline

Figures and Tables

Figures(9)  /  Tables(6)

Other Articles By Authors

/

DownLoad:  Full-Size Img  PowerPoint
Return
Return

Catalog