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

Stockformer: A Price-Volume Factor Stock Selection Model Based on Wavelet Transform and Multi-Task Self-Attention Networks

Author

Listed:
  • Bohan Ma
  • Yushan Xue
  • Yuan Lu
  • Jing Chen

Abstract

As the Chinese stock market continues to evolve and its market structure grows increasingly complex, traditional quantitative trading methods are facing escalating challenges. Particularly, due to policy uncertainty and the frequent market fluctuations triggered by sudden economic events, existing models often struggle to accurately predict market dynamics. To address these challenges, this paper introduces Stockformer, a price-volume factor stock selection model that integrates wavelet transformation and a multitask self-attention network, aimed at enhancing responsiveness and predictive accuracy regarding market instabilities. Through discrete wavelet transform, Stockformer decomposes stock returns into high and low frequencies, meticulously capturing long-term market trends and short-term fluctuations, including abrupt events. Moreover, the model incorporates a Dual-Frequency Spatiotemporal Encoder and graph embedding techniques to effectively capture complex temporal and spatial relationships among stocks. Employing a multitask learning strategy, it simultaneously predicts stock returns and directional trends. Experimental results show that Stockformer outperforms existing advanced methods on multiple real stock market datasets. In strategy backtesting, Stockformer consistently demonstrates exceptional stability and reliability across market conditions-whether rising, falling, or fluctuating-particularly maintaining high performance during downturns or volatile periods, indicating a high adaptability to market fluctuations. To foster innovation and collaboration in the financial analysis sector, the Stockformer model's code has been open-sourced and is available on the GitHub repository: https://github.com/Eric991005/Multitask-Stockformer.

Suggested Citation

  • Bohan Ma & Yushan Xue & Yuan Lu & Jing Chen, 2023. "Stockformer: A Price-Volume Factor Stock Selection Model Based on Wavelet Transform and Multi-Task Self-Attention Networks," Papers 2401.06139, arXiv.org, revised Jun 2024.
  • Handle: RePEc:arx:papers:2401.06139
    as

    Download full text from publisher

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

    References listed on IDEAS

    as
    1. Fama, Eugene F & French, Kenneth R, 1992. "The Cross-Section of Expected Stock Returns," Journal of Finance, American Finance Association, vol. 47(2), pages 427-465, June.
    2. Krauss, Christopher & Do, Xuan Anh & Huck, Nicolas, 2017. "Deep neural networks, gradient-boosted trees, random forests: Statistical arbitrage on the S&P 500," European Journal of Operational Research, Elsevier, vol. 259(2), pages 689-702.
    3. Ross, Stephen A, 1977. "The Capital Asset Pricing Model (CAPM), Short-Sale Restrictions and Related Issues," Journal of Finance, American Finance Association, vol. 32(1), pages 177-183, March.
    4. Fama, Eugene F. & French, Kenneth R., 2015. "A five-factor asset pricing model," Journal of Financial Economics, Elsevier, vol. 116(1), pages 1-22.
    5. Fung, William & Hsieh, David A, 1997. "Empirical Characteristics of Dynamic Trading Strategies: The Case of Hedge Funds," The Review of Financial Studies, Society for Financial Studies, vol. 10(2), pages 275-302.
    6. Jeremiah Green & John R. M. Hand & X. Frank Zhang, 2017. "The Characteristics that Provide Independent Information about Average U.S. Monthly Stock Returns," The Review of Financial Studies, Society for Financial Studies, vol. 30(12), pages 4389-4436.
    7. Jujie Wang & Zhenzhen Zhuang & Liu Feng, 2022. "Intelligent Optimization Based Multi-Factor Deep Learning Stock Selection Model and Quantitative Trading Strategy," Mathematics, MDPI, vol. 10(4), pages 1-19, February.
    Full references (including those not matched with items on IDEAS)

    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. Rungmaitree, Pattamon & Boateng, Agyenim & Ahiabor, Frederick & Lu, Qinye, 2022. "Political risk, hedge fund strategies, and returns: Evidence from G7 countries," Journal of International Financial Markets, Institutions and Money, Elsevier, vol. 81(C).
    2. François-Éric Racicot & Raymond Théoret, 2022. "Tracking market and non-traditional sources of risks in procyclical and countercyclical hedge fund strategies under extreme scenarios: a nonlinear VAR approach," Financial Innovation, Springer;Southwestern University of Finance and Economics, vol. 8(1), pages 1-56, December.
    3. Kentaro Imajo & Kentaro Minami & Katsuya Ito & Kei Nakagawa, 2020. "Deep Portfolio Optimization via Distributional Prediction of Residual Factors," Papers 2012.07245, arXiv.org.
    4. Vitor Azevedo & Christopher Hoegner, 2023. "Enhancing stock market anomalies with machine learning," Review of Quantitative Finance and Accounting, Springer, vol. 60(1), pages 195-230, January.
    5. Andrew Y. Chen & Jack McCoy, 2022. "Missing Values Handling for Machine Learning Portfolios," Papers 2207.13071, arXiv.org, revised Jan 2024.
    6. Guillaume Coqueret & Tony Guida, 2020. "Training trees on tails with applications to portfolio choice," Post-Print hal-04144665, HAL.
    7. Guillaume Chevalier & Guillaume Coqueret & Thomas Raffinot, 2022. "Supervised portfolios," Post-Print hal-04144588, HAL.
    8. Pawel Dlotko & Wanling Qiu & Simon Rudkin, 2019. "Financial ratios and stock returns reappraised through a topological data analysis lens," Papers 1911.10297, arXiv.org.
    9. Pedro M. Mirete-Ferrer & Alberto Garcia-Garcia & Juan Samuel Baixauli-Soler & Maria A. Prats, 2022. "A Review on Machine Learning for Asset Management," Risks, MDPI, vol. 10(4), pages 1-46, April.
    10. Uddin, Ajim & Yu, Dantong, 2020. "Latent factor model for asset pricing," Journal of Behavioral and Experimental Finance, Elsevier, vol. 27(C).
    11. Tobek, Ondrej & Hronec, Martin, 2021. "Does it pay to follow anomalies research? Machine learning approach with international evidence," Journal of Financial Markets, Elsevier, vol. 56(C).
    12. Ali, Sara & Badshah, Ihsan & Demirer, Riza, 2022. "Value-at-risk and the cross section of emerging market hedge fund returns," Global Finance Journal, Elsevier, vol. 52(C).
    13. Ma, Tian & Leong, Wen Jun & Jiang, Fuwei, 2023. "A latent factor model for the Chinese stock market," International Review of Financial Analysis, Elsevier, vol. 87(C).
    14. Guillaume Coqueret & Tony Guida, 2020. "Training trees on tails with applications to portfolio choice," Annals of Operations Research, Springer, vol. 288(1), pages 181-221, May.
    15. Liu, Chenxi & Kang, Mengyao, 2024. "Is the cash-returns relationship risk induced?," The North American Journal of Economics and Finance, Elsevier, vol. 69(PA).
    16. Joachim Freyberger & Andreas Neuhierl & Michael Weber, 2020. "Dissecting Characteristics Nonparametrically," The Review of Financial Studies, Society for Financial Studies, vol. 33(5), pages 2326-2377.
    17. Vitor Azevedo & Georg Sebastian Kaiser & Sebastian Mueller, 2023. "Stock market anomalies and machine learning across the globe," Journal of Asset Management, Palgrave Macmillan, vol. 24(5), pages 419-441, September.
    18. Cho, Thummim, 2018. "Turning alphas into betas: arbitrage and the cross-section of risk," LSE Research Online Documents on Economics 118915, London School of Economics and Political Science, LSE Library.
    19. Matthew Clegg & Christopher Krauss, 2018. "Pairs trading with partial cointegration," Quantitative Finance, Taylor & Francis Journals, vol. 18(1), pages 121-138, January.
    20. Han, Xing & Li, Kai & Li, Youwei, 2020. "Investor overconfidence and the security market line: New evidence from China," Journal of Economic Dynamics and Control, Elsevier, vol. 117(C).

    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:2401.06139. 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.