Table of Contents
Fetching ...

FinMamba: Market-Aware Graph Enhanced Multi-Level Mamba for Stock Movement Prediction

Yifan Hu, Peiyuan Liu, Yuante Li, Dawei Cheng, Naiqi Li, Tao Dai, Jigang Bao, Shu-Tao Xia

TL;DR

FinMamba addresses dynamic inter-stock relationships and pattern-oriented dependencies in stock movement prediction by jointly modeling a Market-Aware Graph (MAG) and a Multi-Level Mamba (MLM). MAG combines posterior short-term correlations with priors from industry structure and refines edges using market-index feedback, while MLM captures multi-scale movement patterns through level-specific state-space blocks. The framework optimizes a joint loss that blends regression/ranking objectives with a GIB-based regularizer to reduce graph information bottlenecks. Extensive experiments across U.S. and Chinese markets show state-of-the-art predictive performance and robust trading profitability with linear-time graph handling, highlighting FinMamba’s potential for real-time quantitative trading under varying market conditions.

Abstract

Recently, combining stock features with inter-stock correlations has become a common and effective approach for stock movement prediction. However, financial data presents significant challenges due to its low signal-to-noise ratio and the dynamic complexity of the market, which give rise to two key limitations in existing methods. First, the relationships between stocks are highly influenced by multifaceted factors including macroeconomic market dynamics, and current models fail to adaptively capture these evolving interactions under specific market conditions. Second, for the accuracy and timeliness required by real-world trading, existing financial data mining methods struggle to extract beneficial pattern-oriented dependencies from long historical data while maintaining high efficiency and low memory consumption. To address the limitations, we propose FinMamba, a Mamba-GNN-based framework for market-aware and multi-level hybrid stock movement prediction. Specifically, we devise a dynamic graph to learn the changing representations of inter-stock relationships by integrating a pruning module that adapts to market trends. Afterward, with a selective mechanism, the multi-level Mamba discards irrelevant information and resets states to skillfully recall historical patterns across multiple time scales with linear time costs, which are then jointly optimized for reliable prediction. Extensive experiments on U.S. and Chinese stock markets demonstrate the effectiveness of our proposed FinMamba, achieving state-of-the-art prediction accuracy and trading profitability, while maintaining low computational complexity. The code is available at https://github.com/TROUBADOUR000/FinMamba.

FinMamba: Market-Aware Graph Enhanced Multi-Level Mamba for Stock Movement Prediction

TL;DR

FinMamba addresses dynamic inter-stock relationships and pattern-oriented dependencies in stock movement prediction by jointly modeling a Market-Aware Graph (MAG) and a Multi-Level Mamba (MLM). MAG combines posterior short-term correlations with priors from industry structure and refines edges using market-index feedback, while MLM captures multi-scale movement patterns through level-specific state-space blocks. The framework optimizes a joint loss that blends regression/ranking objectives with a GIB-based regularizer to reduce graph information bottlenecks. Extensive experiments across U.S. and Chinese markets show state-of-the-art predictive performance and robust trading profitability with linear-time graph handling, highlighting FinMamba’s potential for real-time quantitative trading under varying market conditions.

Abstract

Recently, combining stock features with inter-stock correlations has become a common and effective approach for stock movement prediction. However, financial data presents significant challenges due to its low signal-to-noise ratio and the dynamic complexity of the market, which give rise to two key limitations in existing methods. First, the relationships between stocks are highly influenced by multifaceted factors including macroeconomic market dynamics, and current models fail to adaptively capture these evolving interactions under specific market conditions. Second, for the accuracy and timeliness required by real-world trading, existing financial data mining methods struggle to extract beneficial pattern-oriented dependencies from long historical data while maintaining high efficiency and low memory consumption. To address the limitations, we propose FinMamba, a Mamba-GNN-based framework for market-aware and multi-level hybrid stock movement prediction. Specifically, we devise a dynamic graph to learn the changing representations of inter-stock relationships by integrating a pruning module that adapts to market trends. Afterward, with a selective mechanism, the multi-level Mamba discards irrelevant information and resets states to skillfully recall historical patterns across multiple time scales with linear time costs, which are then jointly optimized for reliable prediction. Extensive experiments on U.S. and Chinese stock markets demonstrate the effectiveness of our proposed FinMamba, achieving state-of-the-art prediction accuracy and trading profitability, while maintaining low computational complexity. The code is available at https://github.com/TROUBADOUR000/FinMamba.

Paper Structure

This paper contains 37 sections, 11 equations, 10 figures, 3 tables.

Figures (10)

  • Figure 1: Market fluctuations have affected the correlation among stocks. In the heatmap above, the horizontal axis represents trading days, while the vertical axis displays the average correlation of each stock with other stocks on a given day. The line chart below reflects the macroeconomic market volatility. The analysis reveals that, during past market downturns, stock correlations tend to intensify. A discernible pattern emerges: stock correlations increase when the market index falls and diminish when the market index rises.
  • Figure 2: Comparison of (a) Transformer's self-attention mechanism and (b) Mamba's selective mechanism in stock movement prediction. Mamba is more effective in recalling similar historical patterns and avoiding overemphasis on outliers compared to Transformer.
  • Figure 3: Stock movements among different primary and secondary industries.
  • Figure 4: Overall structure of proposed FinMamba. 1. Market-Aware Graph models both the prior long-term and the posterior short-term correlations between stocks and adaptively selects dominant relationships based on macroeconomic market index trends. 2. Multi-Level Mamba captures similar stock movement patterns across both coarse-grained and fine-grained levels.
  • Figure 5: (a) a to d and e to h represent two groups of similar stock movement patterns. FinMamba effectively captures strong intra-group correlations and exhibits low inter-group correlations. (b) Our proposed FinMamba demonstrates superior efficiency and effectiveness, achieving lower inference time (ms/iter) and reduced memory usage (MB) with longer lookback horizons.
  • ...and 5 more figures