Clustering Behavioral Regimes in the Iranian Capital Market Using Self-Organizing Maps (SOM): An Unsupervised Learning Approach (A Proof-of-Concept Study)
Keywords:
Iranian Capital Market, Self-Organizing Map, SOM, Unsupervised Learning, Behavioral Regimes, Clustering, U-Matrix, Machine LearningAbstract
This study aimed to evaluate, as a proof of concept, the capability of a Self-Organizing Map (SOM) to identify and characterize latent behavioral regimes in multidimensional Iranian capital-market data through an unsupervised learning framework. This quantitative, computational, exploratory, and applied study used multivariate financial observations representing dimensions such as return, volatility, trading activity, market conditions, and selected firm-level characteristics. After data cleaning, assessment of missing and extreme values, temporal alignment, and scaling, the observations were entered into a two-dimensional 6 × 6 SOM implemented in Python using the MiniSom library. The model used a Gaussian neighborhood function, an initial learning rate of 0.50, and 1,000 training iterations. Cluster extraction was based on the topological organization of the trained map and U-Matrix patterns. Model performance was assessed using training and quantization error, intra-cluster distance, visual inspection of the U-Matrix, and cluster-validity criteria including the Silhouette coefficient and Davies–Bouldin index. The network training error decreased from 0.482 to 0.067, representing an approximate reduction of 86.1% and indicating substantial convergence during learning. U-Matrix analysis revealed nonuniform inter-neuron distances and distinguishable topological regions, supporting the existence of heterogeneous latent structures. Four final clusters were extracted. Cluster 1 contained 175 observations and showed the greatest internal cohesion with a mean intra-cluster distance of 0.23; Cluster 2 contained 152 observations with a mean distance of 0.31; Cluster 3 included 108 observations with a mean distance of 0.44; and Cluster 4 included 85 observations and exhibited the greatest heterogeneity with a mean intra-cluster distance of 0.51. The findings indicate that SOM can provide a meaningful unsupervised representation of heterogeneous behavioral regimes in Iranian capital-market data and may serve as a useful exploratory foundation for subsequent regime-based forecasting, portfolio management, and risk-monitoring studies.
References
[1] M. M. Ebrahimzadeh, Y. Ahadi Sarkani, and M. Mahmoudi, "Developing a capital market behavior model based on information type and market symmetry using a grounded theory approach," (in English), Quarterly Journal of Economic Research and Policies, vol. 33, no. 115, pp. 138-177, 2025.
[2] H. Babaei, N. Rezaei, A. Pakmaram, and R. Abdi, "Identifying behavioral financial components using emotional-cognitive dimensions and its role in the capital market crisis," Iranian Journal of Accounting, Auditing and Finance, vol. 9, no. 3, pp. 53-80, 2025, doi: 10.22067/ijaaf.2025.45734.1465.
[3] M. Ahmed, N. Kumar, and H. Maqsood, "Taxation and Investor Behavior: Analyzing Portfolio Adjustments, Risk Preferences, and Capital Market Reactions to Fiscal Policy Changes," JBMR, vol. 4, no. 2, pp. 1-26, 2025, doi: 10.64105/jbmr.04.02.374.
[4] T. Das, A. Halder, and G. Saha, "Application of density-based clustering approaches for stock market analysis," Applied Artificial Intelligence, vol. 38, no. 1, p. 2321550, 2024, doi: 10.1080/08839514.2024.2321550.
[5] J. Sass and A. K. Thös, "Risk reduction and portfolio optimization using clustering methods," Econometrics and Statistics, vol. 32, pp. 1-16, 2024, doi: 10.1016/j.ecosta.2021.11.010.
[6] D. Wu, X. Wang, and S. Wu, "Construction of stock portfolios based on k-means clustering of continuous trend features," Knowledge-Based Systems, vol. 252, p. 109358, 2022, doi: 10.1016/j.knosys.2022.109358.
[7] J. Vásquez Sáenz, F. M. Quiroga, and A. F. Bariviera, "Data vs. information: Using clustering techniques to enhance stock returns forecasting," International Review of Financial Analysis, vol. 88, p. 102657, 2023, doi: 10.1016/j.irfa.2023.102657.
[8] I. K. Nti, A. F. Adekoya, and B. A. Weyori, "A systematic review of fundamental and technical analysis of stock market predictions," Artificial Intelligence Review, vol. 53, pp. 3007-3057, 2020, doi: 10.1007/s10462-019-09754-z.
[9] M. Mehrabanpour and M. Habibzadeh, "Clustering and predicting the profitability of companies listed on the Tehran Stock Exchange using a C5 decision tree approach," Empirical Studies in Financial Accounting, vol. 15, no. 59, pp. 135-137, 2018.
[10] T. Kohonen, Self-Organizing Maps, 3 ed. Springer, 2001.
[11] A. Javed, D. M. Rizzo, B. S. Lee, and R. Gramling, "Somtimes: Self organizing maps for time series clustering and its application to serious illness conversations," Data Mining and Knowledge Discovery, vol. 38, pp. 813-839, 2024, doi: 10.1007/s10618-023-00979-9.
[12] D. Pei, C. Luo, and X. Liu, "Financial trading decisions based on deep fuzzy self-organizing map," Applied Soft Computing, vol. 134, p. 109972, 2023, doi: 10.1016/j.asoc.2022.109972.
[13] J. Vesanto and E. Alhoniemi, "Clustering of the self-organizing map," IEEE Transactions on Neural Networks, vol. 11, no. 3, pp. 586-600, 2000, doi: 10.1109/72.846731.
[14] P. J. Rousseeuw, "Silhouettes: A graphical aid to the interpretation and validation of cluster analysis," Journal of Computational and Applied Mathematics, vol. 20, pp. 53-65, 1987, doi: 10.1016/0377-0427(87)90125-7.
[15] M. Shutaywi and N. N. Kachouie, "Silhouette analysis for performance evaluation in machine learning with applications to clustering," Entropy, vol. 23, no. 6, p. 759, 2021, doi: 10.3390/e23060759.
[16] D. L. Davies and D. W. Bouldin, "A cluster separation measure," IEEE Transactions on Pattern Analysis and Machine Intelligence, vol. PAMI-1, no. 2, pp. 224-227, 1979, doi: 10.1109/TPAMI.1979.4766909.
Downloads
Publication Timeline
- Submitted
- Revised
- Accepted
Issue
Section
License
Copyright (c) 2025 Mohsen Abbasi Sorkhkolaei (Author); Seyed Ali Nabavi Chashmi; Erfan Memarian (Author)

This work is licensed under a Creative Commons Attribution-NonCommercial 4.0 International License.