Modeling the effects of Tehran Stock Exchange investors' sentiment on stock price within a heterogeneous agent model

Document Type : Original Article


1 PhD Student in Financial Engineering, Department of Management, Rasht Branch, Islamic Azad University, Rasht, Iran

2 Associate Prof, Department of Management, University of Guilan, Rasht, Iran

3 Assistant prof, Department of Business Management, Rasht Branch, Islamic Azad University, Rasht, Iran.



The purpose of this article is to investigate the effects of investors' sentiments on stock prices and its modeling in the framework of the heterogeneous agent model. In this regard, by using simulation, stock prices are calculated at the time of investors' sentiments, and the results are compared with stock prices in the real market to determine how much the simulated market matches the real market. The current research is descriptive in terms of purpose and content analysis has been used to evaluate the simulation results. Therefore, first, the point of crash of the stock market was determined in the framework of theoretical discussions. Then, the input variables including positive sentiments, negative sentiments and herd behavior were entered into the model and the price simulation process was done for each of the biases during the market crash. Considering the heterogeneous agents in the market and the dynamics of investors' behavior, Monte Carlo simulation was used and coding was done in MATLAB.
By comparing simulated prices with real market prices at the time of investors' sentiments, the model's ability to estimate real market prices was investigated. The research results show that the heterogeneous factor model can predict the effects of investors' emotions when the stock market falls. Especially when negative emotions appear in the market, the presented model provides the best estimate compared to the real market.


) Marwat, Habib and Ghasemi, Abbas and Hakami, Hassan (2016),) A simple model to explain the dynamics of the total stock market price index of Tehran, Quarterly Journal of Economic Modeling Research, No. 23, Spring 2016, pp. 257-233.
2) Brown, G., & Cliff, M. (2004). Investor sentiment and the near-term stock market, Journal of Empirical Finance, vol. 11, issue 1, 1-27.
3) Vakilifard, Hamidreza; Khoshnood, Mehdi; Foroughnejad, Haidar (1393). Factor-based modeling in financial markets. Journal of Investment Knowledge, 139-158.
4) Chiarella, Carl, Xuezhong He, Zwinkels R.C. (2013). Heterogeneous Expectations in Asset Pricing: Evidence from the S&P٥٠٠. Working paper: university.
5) Kukacka,J , Barunik J,. (2013). Behavioral breaks in the heterogeneous agent model: The impact of herding, overconfidence, and market sentiment. Physica A 392, 5920-5938.
6) Baker, M. & J. Wurgler (2007): “Investor Sentiment in the Stock Market.” The Journal of Economic Perspectives 21: pp. 129–151
7) Barun´ık, J., L. Vacha, & M. Voˇsvrda (2009): “Smart Predictors in the Heterogeneous Agent Model.” Journal of Economic Interaction and Coordination 4: pp. 163–172.
Economic Interaction and Coordination 4: pp. 163–172.
8) Brock, W. A., C. H. Hommes, & F. O. O. Wagener (2005): “Evolutionary Dynamics in 
assets such as future contracts based on the model
9) Gol Arzi, Gholamhossein and Ziachi, Ali Asghar (2014),)) A Study of Collective Behavior of Investors in Tehran Stock Exchange with an Approach Based on 
Trading Volume Quarterly Journal of Securities Analysis, No. 16
10) Lux, T. (2010): “Financial Power Laws: Empirical Evidence, Models, and Mechanism.” Technical report, University of Kiel, Germany.
11) Hamid Reza Vakili Fard (2014), factor-based modeling in financial markets, investment knowledge quarterly
12) Boswijk, H.P., C.H. Hommes and S. Manzan. (2007). Behavioral Hetero-geneity in Stock Prices, vol 31. Journal of Economic Dynamics and Control, 1938-1970.
13)Brock, W. H. (1997). A Rational route to randomness. Econometrica, Vol 65, No 5, 1059-.5901
14)Brock, W.A., Hommes, C.H. (1998). eterogeneous beliefs and routes to chaos in a simple asset pricing model. Journal of Economic Dynamics and Control 22, 1235.4721 18) Chiarella, Carl, Xuezhong He, Zwinkels R.C. (2010). Heterogeneous Expectations in Asset Pricing
15)Vacha, L., J. Barun´ık, & M. Voˇsvrda (2009): “Smart Agents and Sentiment in the Heterogeneous Agent Model.” Prague Economic Papers 3: pp. 209–219.
16) de Jong, E, & R. C. J. Zwinkels (2010): “Heterogeneity of Agents and Exchange Rate Dynamics: Evidence from the EMS.” Journal of International Money and Finance 29: pp. 1652–1669.
17) Fama, E. F. (1970): “Efficient Capital Markets: A Review of Theory and Empirical Work.” The Journal of Finance 25(2): pp. 383–417.
18)Hommes, C.H., Wagener, F. (2008). Complex Evolutionary Systems in B havioral Finance. Amsterdam: CeNDEF Working Papers from Universiteit van Amsterdam, Center for Nonlinear Dynamics in Economics and Finance.
19) Hommes, C. (2006). Heterogeneous agent models in economics and finance. Handbook of Computational Economics, vol. 2, 1109-1186.
20) Hommes, C.H., Sonnemans, J., Tuinstra, J., van de Velden, H. (2005). Coordination of expectations in asset pricing experiments. Review of Financial Studies 18, 955–980.
21) . Kim, Y., Li, H., & Li, S. (2014). Corporate Social Responsibiliy and Stock Price Crash Risk. Journal of Banking &Finance., Elsevier, vol. 43(C), 1-13.
22) Rakik,Y.M & Hachicha,W & Boujelbene,Y (2014), Agent-Based Modeling and Investors Behavior Explanation of Asset Price Dynamics on Artificial Financial Markets, Procedia Economics and Finance, 13,30-46
23) Simon, H. A. (1955): “A Behavioral Model of Rational Choice.” The Quarterly Journal of Economics 69(1): pp. 99–118.