IDEAS home Printed from https://ideas.repec.org/p/arx/papers/2309.12891.html
   My bibliography  Save this paper

EarnHFT: Efficient Hierarchical Reinforcement Learning for High Frequency Trading

Author

Listed:
  • Molei Qin
  • Shuo Sun
  • Wentao Zhang
  • Haochong Xia
  • Xinrun Wang
  • Bo An

Abstract

High-frequency trading (HFT) uses computer algorithms to make trading decisions in short time scales (e.g., second-level), which is widely used in the Cryptocurrency (Crypto) market (e.g., Bitcoin). Reinforcement learning (RL) in financial research has shown stellar performance on many quantitative trading tasks. However, most methods focus on low-frequency trading, e.g., day-level, which cannot be directly applied to HFT because of two challenges. First, RL for HFT involves dealing with extremely long trajectories (e.g., 2.4 million steps per month), which is hard to optimize and evaluate. Second, the dramatic price fluctuations and market trend changes of Crypto make existing algorithms fail to maintain satisfactory performance. To tackle these challenges, we propose an Efficient hieArchical Reinforcement learNing method for High Frequency Trading (EarnHFT), a novel three-stage hierarchical RL framework for HFT. In stage I, we compute a Q-teacher, i.e., the optimal action value based on dynamic programming, for enhancing the performance and training efficiency of second-level RL agents. In stage II, we construct a pool of diverse RL agents for different market trends, distinguished by return rates, where hundreds of RL agents are trained with different preferences of return rates and only a tiny fraction of them will be selected into the pool based on their profitability. In stage III, we train a minute-level router which dynamically picks a second-level agent from the pool to achieve stable performance across different markets. Through extensive experiments in various market trends on Crypto markets in a high-fidelity simulation trading environment, we demonstrate that EarnHFT significantly outperforms 6 state-of-art baselines in 6 popular financial criteria, exceeding the runner-up by 30% in profitability.

Suggested Citation

  • Molei Qin & Shuo Sun & Wentao Zhang & Haochong Xia & Xinrun Wang & Bo An, 2023. "EarnHFT: Efficient Hierarchical Reinforcement Learning for High Frequency Trading," Papers 2309.12891, arXiv.org.
  • Handle: RePEc:arx:papers:2309.12891
    as

    Download full text from publisher

    File URL: http://arxiv.org/pdf/2309.12891
    File Function: Latest version
    Download Restriction: no
    ---><---

    References listed on IDEAS

    as
    1. Chuheng Zhang & Yitong Duan & Xiaoyu Chen & Jianyu Chen & Jian Li & Li Zhao, 2023. "Towards Generalizable Reinforcement Learning for Trade Execution," Papers 2307.11685, arXiv.org.
    2. Chordia, Tarun & Roll, Richard & Subrahmanyam, Avanidhar, 2002. "Order imbalance, liquidity, and market returns," Journal of Financial Economics, Elsevier, vol. 65(1), pages 111-130, July.
    3. Albert Shiryaev & Zuoquan Xu & Xun Yu Zhou, 2008. "Response to comment on 'Thou shalt buy and hold'," Quantitative Finance, Taylor & Francis Journals, vol. 8(8), pages 761-762.
    4. Madhavan, Ananth, 2000. "Market microstructure: A survey," Journal of Financial Markets, Elsevier, vol. 3(3), pages 205-258, August.
    5. Almeida, José & Gonçalves, Tiago Cruz, 2023. "A systematic literature review of investor behavior in the cryptocurrency markets," Journal of Behavioral and Experimental Finance, Elsevier, vol. 37(C).
    6. Albert Shiryaev & Zuoquan Xu & Xun Yu Zhou, 2008. "Thou shalt buy and hold," Quantitative Finance, Taylor & Francis Journals, vol. 8(8), pages 765-776.
    7. Shuo Sun & Wanqi Xue & Rundong Wang & Xu He & Junlei Zhu & Jian Li & Bo An, 2021. "DeepScalper: A Risk-Aware Reinforcement Learning Framework to Capture Fleeting Intraday Trading Opportunities," Papers 2201.09058, arXiv.org, revised Aug 2022.
    8. Volodymyr Mnih & Koray Kavukcuoglu & David Silver & Andrei A. Rusu & Joel Veness & Marc G. Bellemare & Alex Graves & Martin Riedmiller & Andreas K. Fidjeland & Georg Ostrovski & Stig Petersen & Charle, 2015. "Human-level control through deep reinforcement learning," Nature, Nature, vol. 518(7540), pages 529-533, February.
    Full references (including those not matched with items on IDEAS)

    Citations

    Citations are extracted by the CitEc Project, subscribe to its RSS feed for this item.
    as


    Cited by:

    1. Wentao Zhang & Lingxuan Zhao & Haochong Xia & Shuo Sun & Jiaze Sun & Molei Qin & Xinyi Li & Yuqing Zhao & Yilei Zhao & Xinyu Cai & Longtao Zheng & Xinrun Wang & Bo An, 2024. "A Multimodal Foundation Agent for Financial Trading: Tool-Augmented, Diversified, and Generalist," Papers 2402.18485, arXiv.org, revised Jun 2024.
    2. Chuqiao Zong & Chaojie Wang & Molei Qin & Lei Feng & Xinrun Wang & Bo An, 2024. "MacroHFT: Memory Augmented Context-aware Reinforcement Learning On High Frequency Trading," Papers 2406.14537, arXiv.org.
    3. Jian Guo & Heung-Yeung Shum, 2024. "Large Investment Model," Papers 2408.10255, arXiv.org, revised Aug 2024.

    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. Chuqiao Zong & Chaojie Wang & Molei Qin & Lei Feng & Xinrun Wang & Bo An, 2024. "MacroHFT: Memory Augmented Context-aware Reinforcement Learning On High Frequency Trading," Papers 2406.14537, arXiv.org.
    2. Sabri Boubaker & Zhenya Liu & Yaosong Zhan, 2022. "Risk management for crude oil futures: an optimal stopping-timing approach," Annals of Operations Research, Springer, vol. 313(1), pages 9-27, June.
    3. Yiuman Tse & Brian C. McTier & John K. Wald, 2011. "Do Stock Markets Catch the Flu? We examine the impact of influenza on the U.S. stock market. A higher incidence of flu is associated with decreased trading, decreased volatility, and higher bid-ask sp," Working Papers 0004, College of Business, University of Texas at San Antonio.
    4. Nader Karimi & Hirbod Assa & Erfan Salavati & Hojatollah Adibi, 2023. "Calibration of Storage Model by Multi-Stage Statistical and Machine Learning Methods," Computational Economics, Springer;Society for Computational Economics, vol. 62(4), pages 1437-1455, December.
    5. Satya Majumdar & Jean-Philippe Bouchaud, 2008. "Optimal time to sell a stock in the Black-Scholes model: comment on 'Thou shalt buy and hold', by A. Shiryaev, Z. Xu and X.Y. Zhou," Quantitative Finance, Taylor & Francis Journals, vol. 8(8), pages 753-760.
    6. Arcand, Jean-Louis & Hongler, Max-Olivier & Rinaldo, Daniele, 2020. "Increasing risk: Dynamic mean-preserving spreads," Journal of Mathematical Economics, Elsevier, vol. 86(C), pages 69-82.
    7. Yue Liu & Aijun Yang & Jijian Zhang & Jingjing Yao, 2020. "An Optimal Stopping Problem of Detecting Entry Points for Trading Modeled by Geometric Brownian Motion," Computational Economics, Springer;Society for Computational Economics, vol. 55(3), pages 827-843, March.
    8. Söderberg, Jonas, 2008. "Do Macroeconomic Variables Forecast Changes in Liquidity? An Out-of-sample Study on the Order-driven Stock Markets in Scandinavia," CAFO Working Papers 2009:10, Linnaeus University, Centre for Labour Market Policy Research (CAFO), School of Business and Economics.
    9. Tim Leung & Xin Li & Zheng Wang, 2015. "Optimal Multiple Trading Times Under the Exponential OU Model with Transaction Costs," Papers 1504.04682, arXiv.org.
    10. Ponta, Linda & Trinh, Mailan & Raberto, Marco & Scalas, Enrico & Cincotti, Silvano, 2019. "Modeling non-stationarities in high-frequency financial time series," Physica A: Statistical Mechanics and its Applications, Elsevier, vol. 521(C), pages 173-196.
    11. Geoff Willis, 2011. "Pricing, liquidity and the control of dynamic systems in finance and economics," Papers 1105.5503, arXiv.org.
    12. Min Dai & Zhou Yang & Qing Zhang & Qiji Jim Zhu, 2016. "Optimal Trend Following Trading Rules," Mathematics of Operations Research, INFORMS, vol. 41(2), pages 626-642, May.
    13. Fishe, Raymond P. H. & Robe, Michel A., 2004. "The impact of illegal insider trading in dealer and specialist markets: evidence from a natural experiment," Journal of Financial Economics, Elsevier, vol. 71(3), pages 461-488, March.
    14. Jordan Mann & J. Nathan Kutz, 2016. "Dynamic mode decomposition for financial trading strategies," Quantitative Finance, Taylor & Francis Journals, vol. 16(11), pages 1643-1655, November.
    15. Willis, Geoff, 2011. "Why money trickles up – wealth & income distributions," MPRA Paper 30851, University Library of Munich, Germany.
    16. Zuo Quan Xu & Fahuai Yi, 2019. "Optimal redeeming strategy of stock loans under drift uncertainty," Papers 1901.06680, arXiv.org.
    17. Xiongfei Jian & Xun Li & Fahuai Yi, 2014. "Optimal Investment with Stopping in Finite Horizon," Papers 1406.6940, arXiv.org.
    18. Matthieu Wyart & Jean-Philippe Bouchaud & Julien Kockelkoren & Marc Potters & Michele Vettorazzo, 2008. "Relation between bid-ask spread, impact and volatility in order-driven markets," Quantitative Finance, Taylor & Francis Journals, vol. 8(1), pages 41-57.
    19. Christoph Kuhn & Budhi Arta Surya & Bjorn Ulbricht, 2014. "Optimal Selling Time of a Stock under Capital Gains Taxes," Papers 1501.00026, arXiv.org.
    20. Tim Leung & Xin Li & Zheng Wang, 2014. "Optimal Starting-Stopping and Switching of a CIR Process with Fixed Costs," Papers 1411.6080, arXiv.org.

    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:arx:papers:2309.12891. 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: arXiv administrators (email available below). General contact details of provider: http://arxiv.org/ .

    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.