# Exploring Contrarian Degree in the Trading Behavior of China's Stock Market

Authors: Yue Chen; Xiaojian Niu; Yan Zhang
Journal: Complexity
 (2019)

---

## Abstract

We study the contrarian and trend-following trading behavior of market timers in China's stock market. Using a network model to describe interpersonal relationships, we deploy the Ising model to capture trading strategies for both contrarians and followers. With empirical data of China's stock market, we find that contrarians account for 12-14% of trading volume. We further compare the performance of contrarians and followers and demonstrate the inefficiency of China's stock market where timing arbitrage exists. We highlight the fact that while the actual return sequence is driven by followers, the contrarians seize a lot of profitable arbitrage opportunities.


---

## Body

## 1. Introduction

In many emerging markets, the majority of the investors are individuals instead of institutional investors. Individual investors lack investment experience and awareness of risks, and their emotional behavior is an important cause for the violent shock of the stock market. As a result, these markets are immature and often overreacted. We consider agent-based modeling to analyze the ineffective stock market where the price data has inherent laws. A lot of theories and examples of agent-based dynamical system models have been recognized to be useful in financial markets [1–3].To study the strategies of investors characterized by different emotions and attitudes, many works adopt concepts from network-based dynamics [4–6] and the Ising model [7–10]. These models assume that the long-term yield of a stock is mainly determined by its economic fundamentals, whereas short-term fluctuations of its price are mostly influenced by investors’ sentiments or opinions. This further allows describing the dynamics of price and trading volume through microscopic mechanisms in financial markets [11–16]. For example, the log-returns of stock prices have been found to be related to magnetization of spin models. Some work interprets the magnetization to study the mechanisms that create bubbles and crashes in terms of financial markets [17, 18]. Sornette (2014) [12] explained that the Ising-type models are special ABM implementations with which they formulated an “Emerging Intelligence Market Hypothesis”. Wen and Jun (2012) [19, 20] analyzed the interaction between investors and random fluctuations of stock prices based on the Ising model and found that the rate of returns simulated by the model is consistent with the actual situation. Similar work has been done by Bonggyun et al. (2015) [21], as they employed nonlinear Ising model to generate financial return sequence analogous to those of the real sequence. In the literature, many of these works focus on the interaction mechanism and characteristics of simulated stock sequences. In comparison, few studies have quantitatively explored the composition of the real market, particularly how the behavior of different investors drives the market price.In this paper, we study the contrarian and trend-following behavior of investors in China's stock market, which has been discussed by several works [22–24]. Some scholars have revealed that the real stock market has a time-series momentum effect in the short run and a contrarian effect in the long run [23]. Our study define trend-following behavior as following others’ opinions and short-term trends instead of simple momentum. Using empirical stock price data, we formulate trading strategies and construct a network-based Ising-Stock model. In this model, the trading behavior of players contributes to the pricing mechanism. With extensive simulations, we find that contrarian timers account for 12-14% of trading volume. Comparing the performance of contrarians and followers, we further demonstrate the inefficiency of China’s stock markets where timing arbitrage widely exists. Interestingly, we find that the return rate sequence is driven by followers, but the contrarian timers seize a lot of profitable arbitrage opportunities and further promote the stock price to return to its intrinsic value.


## 2. Methods

Our model characterizes the investment strategy of two types of investors. The first type is the contrarian timer. These investors try to judge a trend with the greatest statistical probability based on historical data and seize contrarian opportunities by analyzing the herd actions of investors around them. The second type is the passive follower, who generally follows others’ behavior and the price trend. In our model, both types of investors aim to make profits, and the only difference between them lies in their investing strategies, other than which, these two types of investors are identical with the same initial capital allocation and the same network connection mechanism.


### 2.1. Network-Based Ising-Stock Model

We considerN players in the stock market, with R contrarians and N-R followers, whose interpersonal relationship is described by a scale-free and small-world network [25, 26], where each node represents a player. For each player i, we denote his neighborhood which contains all other players that directly connect to him as Ωi.At each time, each player places a buy (s=+1) or sell (s=-1) order. For simplicity, we assume that each player can only buy or sell one unit of the asset at one time. We denote the average state of the trading behavior as S(-1<S<1). Then S>0 reflects high demand because more investors have chosen to buy the asset instead of selling it, which further leads to an increase in the price. On the other hand, S<0 indicates that supply exceeds demand in the system, pushing down the price and leading to negative yield. In general, we use S to describe the rate of return [15]. Next, we describe the strategy of contrarian timers and passive followers separately.A contrarian believes that stock prices are determined by the intrinsic value of economic fundamentals and influenced by short-term emotional trades. His basic idea is that prices will return to the intrinsic value, so statistical predictions on short-term trends can be made in light of whether the market is overreacting. He has a tendency to act based on reverse thinking, taking the action differently from the majority. Therefore, his decision can be formulated as(1)sit=-1,ifSt-1>Sp_selltand∑j∈Ωisjt-1>01,ifSt-1<Sp_buytand∑j∈Ωisjt-1<0where Sp_sell and Sp_buy denote the thresholds that the contrarian decides to sell or buy. In our model, these two thresholds are determined by the predicted return rate Sp(t) related to the sequence “r1,r2,…,rt-1”, all of which is data before time t. To account for the fact that more recent information should have a higher impact on contrarians’ expectations than past information, each data point is weighted by a normal distribution function of time. As such Sp(t) is defined as(2)Spt=∑i=1t-1e-δ∗i-t/t2ri∑i=1t-1e-δ∗i-t/t2,where t/δ refers to the closest time period to time t. Here, we adjust δ for t to make t/δ≤20 (nearly number of trading days in one month). We further assume that the contrarians care not only about the long-term dynamic trend but also about the price level in the short term. They take the maximum and minimum return in the latest week (or five trading days) into account to set a threshold over which they can achieve as great yield as possible. The psychological threshold set by these investors should be different for buying and selling, which we formulate as below:(3)Sp_selltSp_buyt=23Spt+13maxminrt-5,rt-4,rt-3,rt-2,rt-1,where we use the long-term trend to smooth the short-term fluctuation of price, and rt determines the logarithmic gain of the actual closing price. Only when S(t-1)>Sp_sell(t) or S(t-1)<Sp_buy(t), will an active timer sell or buy one unit of an asset, respectively. Figure 1(b) shows an example of the action threshold of contrarians based on an actual yield rate sequence.Figure 1
(a) Autocorrelation of log return rate of CSI300 Index from Jan 2004 to Jun 2017. The sequence is autocorrelated within about 20 lags empirically, which is why we sett/δ≤20 in (2). (b) Exception and threshold for trading action by contrarian timers in year 2016. The blue curve is the rate of return of the CSI300 Index in 2016. The red curve is the threshold to sell. The yellow curve is the threshold to buy. The black curve is the expectation of the returns.
(a) (b)For a follower, he mostly focuses on second-hand information, which is others’ opinions or judgments, along with the price trend. Thus, he makes decisions mainly based on the connected investors’ behavior, temporary yield, and public expectations. Therefore, the probability that the followeri chooses to buy or sell is(4)Pt=exp⁡-ΔEitN/R1+exp⁡-ΔEitN/R,sit=+111+exp⁡-ΔEitN/R,sit=-1where(5)ΔEit=Ei+t-Ei-t=-2α∑j∈ΩisjtIj+Spt+βrtand(6)Eit=-αsit∑j∈ΩisjtIj+Spt+βrtsit+∑j∈Ωisjtwhere Ωi denotes the sets of nodes that directly connect with i and α is a measure of noise and governs the strength of selection. Ij is the impact of investor j on investor i, defined as(7)Ij≡N·dj∑idiwhich is proportional to the ratio of the degree of node j to the total degree of the network. The higher the degree of node j, the greater the effect it has on node i. Additionally, β captures the relative intensity factor of r, and a higher β indicates that followers rely more on the rate of return at the previous time.We can draw an analogy between the parameters in the classic Ising model and our model. Concretely,(Sp+βr) constitutes the external information of the system, corresponding to the external magnetic field He of the Ising model. The temperature T in the Ising model is replaced by the proportion of contrarians R/N to describe the internal energy of the market, where a higher R/N brings more free energy for players to trade, which will increase the randomness of investor behavior and drive S to zero faster. Consider an extreme case in which R/N→0 and Pfollower(si=-1)=1. Thus, when ΔEi>0, si collapses to the state -1, whereas si collapses to the state +1  when ΔEi<0. In this case, the average state S never reaches zero, so the market is never balanced. The market will generate more internal energy when it has more contrarians, getting rid of blind investment more easily and achieving a balanced business.We define the above model as the Ising-Stock model and summarize the analogy between the Ising-Stock model and the classic Ising model in Table1.Table 1
Correspondence between Ising-Stock model and Ising model.
Ising model Ising-Stock model s i = + 1(Spin-up) s i = + 1 (Buy) s i = - 1 (Spin-down) s i = - 1 (Sell) S(Average spin) S (Average normalized price) J (Coupling coefficient) I(Impact factor between two investors) H e (External magnetic field) S p + β r (External information) T(Temperature of the system) R / N (Proportion of contrarians) 1 / k(Reciprocal of Boltzmann constant) α (Energy amplification factor)


### 2.2. Stock Data Simulation

Having formulated our model, now we describe how we simulate the stock price and compare it to the empirical value. In China’s stock market, the daily limit of the return rate is 10%, which means that the price of a stock can only go up (down) by 10% even though everyone wants to buy (sell) it, so the return should stay in the range(-ln⁡1.1,ln⁡1.1). Assuming that players are in a continuous auction with a particular number of transactions per second, the turnover and deal price will affect the transaction at the next second. The closing price is the result of the day’s overall trading behavior, contributing to reciprocal causation together with the rate of return.We denote the average cash flow at each timet held by the contrarians, followers, and all players as CaR(t), CaF(t), and Ca(t), respectively. These indicators can be calculated as(8)CaRtCaFtCat=-∑t′=1tCt′1R∑i∈Rsit′1N-R∑i∈N-Rsit′1N∑i∈Nsit′.We select a sequence of the daily closing price of a stock index to calculate rt, and we substitute it into (6) to simulate the yield rate sequence St by the Ising-Stock model. In order to compare the simulated sequence with the actual data sequence to determine whether the simulated and actual behavior of investors are aligned, we define the objective function η as the correlation coefficient over the deviation between the sequence rt and St with length of n:(9)η=∑trt-r¯St-S¯/∑trt-r¯2∑tSt-S¯2∑tSt-rt/nrt.Next, we tune the parameters to maximizeη, so that the investor structure can finally be determined. To compare the popularity of contrarian timing operations in different periods, the proportion of contrarians, R/N, may partly help. However, even contrarians may sometimes make herd decisions due to limited information, whereas followers may make contrarian choices to gain yield by following some contrarians. Therefore, another indicator should be set to quantify the contrarian degree (CD, for short), as below.(10)CDR=1t∑t′=1t12+∑i∈Rsit′2R,(11)CDF=1tN-R∑t′=1t∑j∈N-Rmin⁡Psjt′=1,Psjt′=-1,(12)CD=RN·CDR+N-RN·CDFThe contrarian degree of contrarian timers (CDR) is defined as the proportion of contrarian timers who make the decision that is made by most contrarian timers. The contrarian degree of followers (CDF) refers to the probability of a follower making a decision that is different from that of most followers, which is why we take the minimum value of probabilities of two different states, as min⁡[p(s=1),p(s=-1)]. The average contrarian degree of all investors (CD) is a weighted average of the CDR and the CDF. A higher contrarian degree means that reversal operations are more popular and trends are easier to be traded away; otherwise, investors are more inclined to follow the price trend or others’ behavior. We will use these indicators to compare the performance of these two types of investors.


## 2.1. Network-Based Ising-Stock Model

We considerN players in the stock market, with R contrarians and N-R followers, whose interpersonal relationship is described by a scale-free and small-world network [25, 26], where each node represents a player. For each player i, we denote his neighborhood which contains all other players that directly connect to him as Ωi.At each time, each player places a buy (s=+1) or sell (s=-1) order. For simplicity, we assume that each player can only buy or sell one unit of the asset at one time. We denote the average state of the trading behavior as S(-1<S<1). Then S>0 reflects high demand because more investors have chosen to buy the asset instead of selling it, which further leads to an increase in the price. On the other hand, S<0 indicates that supply exceeds demand in the system, pushing down the price and leading to negative yield. In general, we use S to describe the rate of return [15]. Next, we describe the strategy of contrarian timers and passive followers separately.A contrarian believes that stock prices are determined by the intrinsic value of economic fundamentals and influenced by short-term emotional trades. His basic idea is that prices will return to the intrinsic value, so statistical predictions on short-term trends can be made in light of whether the market is overreacting. He has a tendency to act based on reverse thinking, taking the action differently from the majority. Therefore, his decision can be formulated as(1)sit=-1,ifSt-1>Sp_selltand∑j∈Ωisjt-1>01,ifSt-1<Sp_buytand∑j∈Ωisjt-1<0where Sp_sell and Sp_buy denote the thresholds that the contrarian decides to sell or buy. In our model, these two thresholds are determined by the predicted return rate Sp(t) related to the sequence “r1,r2,…,rt-1”, all of which is data before time t. To account for the fact that more recent information should have a higher impact on contrarians’ expectations than past information, each data point is weighted by a normal distribution function of time. As such Sp(t) is defined as(2)Spt=∑i=1t-1e-δ∗i-t/t2ri∑i=1t-1e-δ∗i-t/t2,where t/δ refers to the closest time period to time t. Here, we adjust δ for t to make t/δ≤20 (nearly number of trading days in one month). We further assume that the contrarians care not only about the long-term dynamic trend but also about the price level in the short term. They take the maximum and minimum return in the latest week (or five trading days) into account to set a threshold over which they can achieve as great yield as possible. The psychological threshold set by these investors should be different for buying and selling, which we formulate as below:(3)Sp_selltSp_buyt=23Spt+13maxminrt-5,rt-4,rt-3,rt-2,rt-1,where we use the long-term trend to smooth the short-term fluctuation of price, and rt determines the logarithmic gain of the actual closing price. Only when S(t-1)>Sp_sell(t) or S(t-1)<Sp_buy(t), will an active timer sell or buy one unit of an asset, respectively. Figure 1(b) shows an example of the action threshold of contrarians based on an actual yield rate sequence.Figure 1
(a) Autocorrelation of log return rate of CSI300 Index from Jan 2004 to Jun 2017. The sequence is autocorrelated within about 20 lags empirically, which is why we sett/δ≤20 in (2). (b) Exception and threshold for trading action by contrarian timers in year 2016. The blue curve is the rate of return of the CSI300 Index in 2016. The red curve is the threshold to sell. The yellow curve is the threshold to buy. The black curve is the expectation of the returns.
(a) (b)For a follower, he mostly focuses on second-hand information, which is others’ opinions or judgments, along with the price trend. Thus, he makes decisions mainly based on the connected investors’ behavior, temporary yield, and public expectations. Therefore, the probability that the followeri chooses to buy or sell is(4)Pt=exp⁡-ΔEitN/R1+exp⁡-ΔEitN/R,sit=+111+exp⁡-ΔEitN/R,sit=-1where(5)ΔEit=Ei+t-Ei-t=-2α∑j∈ΩisjtIj+Spt+βrtand(6)Eit=-αsit∑j∈ΩisjtIj+Spt+βrtsit+∑j∈Ωisjtwhere Ωi denotes the sets of nodes that directly connect with i and α is a measure of noise and governs the strength of selection. Ij is the impact of investor j on investor i, defined as(7)Ij≡N·dj∑idiwhich is proportional to the ratio of the degree of node j to the total degree of the network. The higher the degree of node j, the greater the effect it has on node i. Additionally, β captures the relative intensity factor of r, and a higher β indicates that followers rely more on the rate of return at the previous time.We can draw an analogy between the parameters in the classic Ising model and our model. Concretely,(Sp+βr) constitutes the external information of the system, corresponding to the external magnetic field He of the Ising model. The temperature T in the Ising model is replaced by the proportion of contrarians R/N to describe the internal energy of the market, where a higher R/N brings more free energy for players to trade, which will increase the randomness of investor behavior and drive S to zero faster. Consider an extreme case in which R/N→0 and Pfollower(si=-1)=1. Thus, when ΔEi>0, si collapses to the state -1, whereas si collapses to the state +1  when ΔEi<0. In this case, the average state S never reaches zero, so the market is never balanced. The market will generate more internal energy when it has more contrarians, getting rid of blind investment more easily and achieving a balanced business.We define the above model as the Ising-Stock model and summarize the analogy between the Ising-Stock model and the classic Ising model in Table1.Table 1
Correspondence between Ising-Stock model and Ising model.
Ising model Ising-Stock model s i = + 1(Spin-up) s i = + 1 (Buy) s i = - 1 (Spin-down) s i = - 1 (Sell) S(Average spin) S (Average normalized price) J (Coupling coefficient) I(Impact factor between two investors) H e (External magnetic field) S p + β r (External information) T(Temperature of the system) R / N (Proportion of contrarians) 1 / k(Reciprocal of Boltzmann constant) α (Energy amplification factor)


## 2.2. Stock Data Simulation

Having formulated our model, now we describe how we simulate the stock price and compare it to the empirical value. In China’s stock market, the daily limit of the return rate is 10%, which means that the price of a stock can only go up (down) by 10% even though everyone wants to buy (sell) it, so the return should stay in the range(-ln⁡1.1,ln⁡1.1). Assuming that players are in a continuous auction with a particular number of transactions per second, the turnover and deal price will affect the transaction at the next second. The closing price is the result of the day’s overall trading behavior, contributing to reciprocal causation together with the rate of return.We denote the average cash flow at each timet held by the contrarians, followers, and all players as CaR(t), CaF(t), and Ca(t), respectively. These indicators can be calculated as(8)CaRtCaFtCat=-∑t′=1tCt′1R∑i∈Rsit′1N-R∑i∈N-Rsit′1N∑i∈Nsit′.We select a sequence of the daily closing price of a stock index to calculate rt, and we substitute it into (6) to simulate the yield rate sequence St by the Ising-Stock model. In order to compare the simulated sequence with the actual data sequence to determine whether the simulated and actual behavior of investors are aligned, we define the objective function η as the correlation coefficient over the deviation between the sequence rt and St with length of n:(9)η=∑trt-r¯St-S¯/∑trt-r¯2∑tSt-S¯2∑tSt-rt/nrt.Next, we tune the parameters to maximizeη, so that the investor structure can finally be determined. To compare the popularity of contrarian timing operations in different periods, the proportion of contrarians, R/N, may partly help. However, even contrarians may sometimes make herd decisions due to limited information, whereas followers may make contrarian choices to gain yield by following some contrarians. Therefore, another indicator should be set to quantify the contrarian degree (CD, for short), as below.(10)CDR=1t∑t′=1t12+∑i∈Rsit′2R,(11)CDF=1tN-R∑t′=1t∑j∈N-Rmin⁡Psjt′=1,Psjt′=-1,(12)CD=RN·CDR+N-RN·CDFThe contrarian degree of contrarian timers (CDR) is defined as the proportion of contrarian timers who make the decision that is made by most contrarian timers. The contrarian degree of followers (CDF) refers to the probability of a follower making a decision that is different from that of most followers, which is why we take the minimum value of probabilities of two different states, as min⁡[p(s=1),p(s=-1)]. The average contrarian degree of all investors (CD) is a weighted average of the CDR and the CDF. A higher contrarian degree means that reversal operations are more popular and trends are easier to be traded away; otherwise, investors are more inclined to follow the price trend or others’ behavior. We will use these indicators to compare the performance of these two types of investors.


## 3. Results

### 3.1. Data Description

As an empirical basis, we use a data set that covers 13 years of daily quotes of the CSI300 Index, from1st of January 2004 to the 30th of June 2017. This period contains 3,277 daily returns, of which the main statistical properties are given in Table 3. Based on this data set, we estimate the contrarian degree of China’s stock market on a half-year basis.


### 3.2. Model Calibration

First, we construct a network of 1000 players, using an extended version of the Watts-Strogatz model as described in the appendix. This network keeps many stylized facts of empirical social networks, such as the high clustering coefficient and low average path length (we have also tested other network structures of different parameters, which do not change our main results). Second, the variableβ is determined as 1000. Assuming no significant difference in the impact of the surrounding investors’ behavior and that of stock returns on followers, it is necessary to adjust β so that the first and second portions of the right side of (6) are of the same order of magnitude. Since the average log yield of the stock index is on the 10-2 level, we take β=100. The remaining variables are the energy adjustment factor, α, and the amount of contrarians, R; these two parameters will be calibrated by comparing the simulated sequence and the real sequence. For clarity, we summarize the parameters used in our model in Table 2.Table 2
Description of parameters.
Parameters Description Remark N the number of agents in the network 1000 K half of the average number of edges of each agent 5 p the rewiring probability of the network 0.08 β the adjustment factor of the daily return 100 α the measure of strength of selection tuned to maximize the objective function R the number of contrarians in the system tuned to maximize the objective functionTable 3
Comparing statistical properties of the empirical data and simulated data.
mean standard deviation kurtosis skewness quantile 0.05 quantile 0.25 quantile 0.75 quantile 0.95 real data 0.05 % 1.77 % 3.43 - 0.34 - 2.81 % - 0.78 % 0.93 % 2.84 % simulation 0.06 % 1.88 % 2.99 - 0.32 - 2.91 % - 0.89 % 1.06 % 2.93 % error 12.80 % 6.21 % 12.73 % 5.25 % 3.56 % 14.10 % 13.98 % 3.17 %To identify the optimalR and α that maximize the objective function η, Figure 2 displays the changing trend of η in α and R. We can see that η achieves the highest value with α=0.002 and Rm=132. With this set of variables, we can reproduce the pattern and the main statistical properties of the stock data sequence. The variables are fitted to the recent market by a rolling window with the length of one year and the step of six months. The simulated sequence well approximates the real one, as shown in Figure 3. In terms of statistical indicators (Table 3), the simulated data has similar properties to the real one, and the relative error of each indicator is within 15%. Particularly, under extreme market conditions (see 5% and 95% quantile), the simulation results well reproduce the performance of the real market.Figure 2
The changing ofη to R and α based on CSI300 data in year 2016.Figure 3
The best simulation and the real stock data sequence. The red curve is the real data and the blue one is the simulated sequence of CSI300 Index from Jan1st 2004 to Jun 30th 2017. Panels (a) and (b), respectively, show the daily return and price simulations, and the starting point of the price is set to be 1.
(a)
Daily return (b)
PriceIn the same way, we obtain the proportion of contrarian timers from January 2004 to June 2017 and the average contrarian degree of the market every six months (Figure4(a)). (To be more precise, the proportion of contrarians in simulation should be understood as the proportion of stock shares traded by contrarians in the real market. According to our model, each player can only change one unit of asset in a transaction, so we have supposed a homogenous distribution of trading volume, which is not true in reality. Thus, R/N cannot directly represent the proportion of contrarians in reality.) The proportion of contrarian timers (the grey curve in Figure 4(b)) does not change substantially, generally fluctuating between 12% and 14%, and has no obvious relationship with changes of quotes, as shown in Figure 4(a). The composition ratios of investors are stable over years. However, changes in the contrarian degree are significant. There are two periods in the given time range when the dumping of stocks is most serious and investors are extremely scared, one in 2007-2008 and the other in 2014-2015. As illustrated in Figure 4(b), both periods display significant volatility in the stock price. In 2007-2008, the global financial crisis occurred after the economic bubble burst, and in 2014-2015, an extreme bull market followed by a crash brought huge volatility. Investors tend to avoid contrarian operations in periods with great volatility, and a favorable turn could occur only when the contrarian degree reaches its rally. Investors in financial markets are rescued or reformed only in desperate circumstances. Between these two periods, the contrarian degree gradually increases from 0.382 to 0.407, and the volatility of the stock market decreases. After the second period, the contrarian degree of China’s stock market greatly improves and reaches its highest point over the period examined. Correspondingly, the stock price rises steadily relative to previous periods since 2016.Figure 4
(a) The contrarian degree CD and the proportion of contrarians R/N of China's stock market from Jan 2004 to Jun 2017. (b) Closing price of the CSI300 Index from Jan 2004 to Jun 2017.
(a) (b)We further compare the contrarian degree of the neighboring bull and bear markets in the given period (Table4). It shows that the contrarian degree of the bull market is often higher than that of the following bear market, which indicates that investors in the bear market are generally more emotional than those in the bull one. In the bearish market, most investors, affected by the unilateral downtrend and panic, will not consider the opportunity of reversal, but only rush to sell assets; in the bull market, investors are little bit more likely to consider the possibility of trend reversal, making the stock price more moderate than that in the bear market. For most investors who are risk-aversion, the grief of losses overwhelms the joy of profits, pushing them to sell more and contribute to greater volatility in the bear market.Table 4
Contrarian degree of bull and bear markets.
Bull Market CD Bear Market CD 2007 0.377 2008 0.349 2009H1 0.382 2010S2 0.379 2014H2-2015H1 0.394 2015S3 0.353 2015S4 0.376 2016S1 0.366 Average 0.382 Average 0.362As a brief summary, we reproduce the real stock sequence with the model and conclude that contrarian timers nearly account for 12-14% of the trading volume. The contrarian degree of the market changes a lot in history. Investors are more likely to take contrarian operations in a moderately fluctuated market than a unilateral-trend market. And the contrarian strategy is less welcomed in the bear market than the bull market.


### 3.3. Comparing Contrarians and Followers

Due to different decision-making methods, contrarians and followers have different performances. The changing trend of the return rate has two driving forces, one caused by contrarians and the other resulting from followers. Thus, we separate these two forces to observe the trading manifestation of the two groups of investors based on CSI300 Index data (Figure5). The common behavior of contrarians is more unequivocal than that of followers, as their curve fluctuates more sharply. Contrarians make decisions more consistently than followers do under this investor construction. The sequence for the contrarians is negatively correlated with the average return rate sequence (the correlation coefficient is -0.592), whereas the sequence for followers is positively related to the average sequence (the correlation coefficient is 0.9687). Thus, the actual return rate sequence is essentially driven by followers, and the trading direction of the contrarians is often inversely related to the price changes. Since contrarians can seize the short-term reversal opportunity, whereas most followers cannot, contrarians gain substantially and followers lose money in our simulated China’s stock market in 2016 (e.g., Figure 6(a)), and the cash gap between the two groups increases as time passes. Moreover, the total amount of cash held by all investors is negative, which means that more cash flows into the stock market, so China’s stock market in 2016 shows a relatively optimistic trend.Figure 5
Changes in the return rate separately caused by the contrarians and followers. Here we setα=0.002, Rm=132. Reference data: daily returns of CSI300 in year 2016.Figure 6
(a) Cash flows of contrarians and followers. Here we setα=0.002, Rm=132. Data resource: quotes of CSI300 Index from Jan 1st 2016 to Dec 31st 2016. (b) Comparison of the average contrarian degree (CD), the contrarian degree of contrarian timers (CDR), and the contrarian degree of followers (CDF).
(a) (b)Turning to the contrarian degree (Figure6(b)), the CDR is always higher than the CDF and follows an inverse trend from that of the CDF and CD. The CDR is at its peak when the CDF reaches its minimum. When the market is in violent oscillation, the polarization of contrarian degree between different investors is quite serious. In other words, the CDR and CDF are closer when the market is gentler. Contrarians are more sensitive to signals of an overheated market than followers, so opportunities for timing arbitrage will become clearer, and contrarians are more willing to take reversal operations when more followers blindly chase the trend. On the other hand, followers are less impetuous when there is no intense trend, and their ambiguous behavior confuses contrarians, in which case, the CDR decreases while the CDF increases, and these two groups become more similar.We last compare the cash flows of contrarians and followers under different years and different proportions of contrarians (Figure7). The four panels all display a polarization of the cash flow at first and then a convergence of the three curves. With an increase in number of contrarians, the cash flow situations of the two groups can converge, which indicates that a homogenous market, in which contrarians cannot be well distinguished from followers, will occur when R/N>25% (an empirical result). If there were a lot of followers, cash would either dump substantially into the stock market (Figures 7(a), 7(b), and 7(d)) or face a large evacuation (Figure 7(c)), whereas the inverse behavior by contrarians could alleviate the situation. As R/N exceeds 25%, the overall market cash flow is maintained at a relatively stable position near zero. Furthermore, the trading behavior of contrarians in a high-CD market is usually the reverse of that in a low-CD market.Figure 7
Changes in average cash flows with an increase ofR/N. The four panels refer to China’s stock market in four different years, and each compares the average cash flows of contrarians and followers.
(a)
2016 (b)
2015 (c)
2008 (d)
2007As a summary, the behavior of followers dominates the trend of China’s stock market prices. But a lot of profitable opportunities are in the hands of contrarians. Contrarians, who usually hold opposite cash flows compared to followers, help to drive distorted prices back to normal levels, especially in extreme markets.


## 3.1. Data Description

As an empirical basis, we use a data set that covers 13 years of daily quotes of the CSI300 Index, from1st of January 2004 to the 30th of June 2017. This period contains 3,277 daily returns, of which the main statistical properties are given in Table 3. Based on this data set, we estimate the contrarian degree of China’s stock market on a half-year basis.


## 3.2. Model Calibration

First, we construct a network of 1000 players, using an extended version of the Watts-Strogatz model as described in the appendix. This network keeps many stylized facts of empirical social networks, such as the high clustering coefficient and low average path length (we have also tested other network structures of different parameters, which do not change our main results). Second, the variableβ is determined as 1000. Assuming no significant difference in the impact of the surrounding investors’ behavior and that of stock returns on followers, it is necessary to adjust β so that the first and second portions of the right side of (6) are of the same order of magnitude. Since the average log yield of the stock index is on the 10-2 level, we take β=100. The remaining variables are the energy adjustment factor, α, and the amount of contrarians, R; these two parameters will be calibrated by comparing the simulated sequence and the real sequence. For clarity, we summarize the parameters used in our model in Table 2.Table 2
Description of parameters.
Parameters Description Remark N the number of agents in the network 1000 K half of the average number of edges of each agent 5 p the rewiring probability of the network 0.08 β the adjustment factor of the daily return 100 α the measure of strength of selection tuned to maximize the objective function R the number of contrarians in the system tuned to maximize the objective functionTable 3
Comparing statistical properties of the empirical data and simulated data.
mean standard deviation kurtosis skewness quantile 0.05 quantile 0.25 quantile 0.75 quantile 0.95 real data 0.05 % 1.77 % 3.43 - 0.34 - 2.81 % - 0.78 % 0.93 % 2.84 % simulation 0.06 % 1.88 % 2.99 - 0.32 - 2.91 % - 0.89 % 1.06 % 2.93 % error 12.80 % 6.21 % 12.73 % 5.25 % 3.56 % 14.10 % 13.98 % 3.17 %To identify the optimalR and α that maximize the objective function η, Figure 2 displays the changing trend of η in α and R. We can see that η achieves the highest value with α=0.002 and Rm=132. With this set of variables, we can reproduce the pattern and the main statistical properties of the stock data sequence. The variables are fitted to the recent market by a rolling window with the length of one year and the step of six months. The simulated sequence well approximates the real one, as shown in Figure 3. In terms of statistical indicators (Table 3), the simulated data has similar properties to the real one, and the relative error of each indicator is within 15%. Particularly, under extreme market conditions (see 5% and 95% quantile), the simulation results well reproduce the performance of the real market.Figure 2
The changing ofη to R and α based on CSI300 data in year 2016.Figure 3
The best simulation and the real stock data sequence. The red curve is the real data and the blue one is the simulated sequence of CSI300 Index from Jan1st 2004 to Jun 30th 2017. Panels (a) and (b), respectively, show the daily return and price simulations, and the starting point of the price is set to be 1.
(a)
Daily return (b)
PriceIn the same way, we obtain the proportion of contrarian timers from January 2004 to June 2017 and the average contrarian degree of the market every six months (Figure4(a)). (To be more precise, the proportion of contrarians in simulation should be understood as the proportion of stock shares traded by contrarians in the real market. According to our model, each player can only change one unit of asset in a transaction, so we have supposed a homogenous distribution of trading volume, which is not true in reality. Thus, R/N cannot directly represent the proportion of contrarians in reality.) The proportion of contrarian timers (the grey curve in Figure 4(b)) does not change substantially, generally fluctuating between 12% and 14%, and has no obvious relationship with changes of quotes, as shown in Figure 4(a). The composition ratios of investors are stable over years. However, changes in the contrarian degree are significant. There are two periods in the given time range when the dumping of stocks is most serious and investors are extremely scared, one in 2007-2008 and the other in 2014-2015. As illustrated in Figure 4(b), both periods display significant volatility in the stock price. In 2007-2008, the global financial crisis occurred after the economic bubble burst, and in 2014-2015, an extreme bull market followed by a crash brought huge volatility. Investors tend to avoid contrarian operations in periods with great volatility, and a favorable turn could occur only when the contrarian degree reaches its rally. Investors in financial markets are rescued or reformed only in desperate circumstances. Between these two periods, the contrarian degree gradually increases from 0.382 to 0.407, and the volatility of the stock market decreases. After the second period, the contrarian degree of China’s stock market greatly improves and reaches its highest point over the period examined. Correspondingly, the stock price rises steadily relative to previous periods since 2016.Figure 4
(a) The contrarian degree CD and the proportion of contrarians R/N of China's stock market from Jan 2004 to Jun 2017. (b) Closing price of the CSI300 Index from Jan 2004 to Jun 2017.
(a) (b)We further compare the contrarian degree of the neighboring bull and bear markets in the given period (Table4). It shows that the contrarian degree of the bull market is often higher than that of the following bear market, which indicates that investors in the bear market are generally more emotional than those in the bull one. In the bearish market, most investors, affected by the unilateral downtrend and panic, will not consider the opportunity of reversal, but only rush to sell assets; in the bull market, investors are little bit more likely to consider the possibility of trend reversal, making the stock price more moderate than that in the bear market. For most investors who are risk-aversion, the grief of losses overwhelms the joy of profits, pushing them to sell more and contribute to greater volatility in the bear market.Table 4
Contrarian degree of bull and bear markets.
Bull Market CD Bear Market CD 2007 0.377 2008 0.349 2009H1 0.382 2010S2 0.379 2014H2-2015H1 0.394 2015S3 0.353 2015S4 0.376 2016S1 0.366 Average 0.382 Average 0.362As a brief summary, we reproduce the real stock sequence with the model and conclude that contrarian timers nearly account for 12-14% of the trading volume. The contrarian degree of the market changes a lot in history. Investors are more likely to take contrarian operations in a moderately fluctuated market than a unilateral-trend market. And the contrarian strategy is less welcomed in the bear market than the bull market.


## 3.3. Comparing Contrarians and Followers

Due to different decision-making methods, contrarians and followers have different performances. The changing trend of the return rate has two driving forces, one caused by contrarians and the other resulting from followers. Thus, we separate these two forces to observe the trading manifestation of the two groups of investors based on CSI300 Index data (Figure5). The common behavior of contrarians is more unequivocal than that of followers, as their curve fluctuates more sharply. Contrarians make decisions more consistently than followers do under this investor construction. The sequence for the contrarians is negatively correlated with the average return rate sequence (the correlation coefficient is -0.592), whereas the sequence for followers is positively related to the average sequence (the correlation coefficient is 0.9687). Thus, the actual return rate sequence is essentially driven by followers, and the trading direction of the contrarians is often inversely related to the price changes. Since contrarians can seize the short-term reversal opportunity, whereas most followers cannot, contrarians gain substantially and followers lose money in our simulated China’s stock market in 2016 (e.g., Figure 6(a)), and the cash gap between the two groups increases as time passes. Moreover, the total amount of cash held by all investors is negative, which means that more cash flows into the stock market, so China’s stock market in 2016 shows a relatively optimistic trend.Figure 5
Changes in the return rate separately caused by the contrarians and followers. Here we setα=0.002, Rm=132. Reference data: daily returns of CSI300 in year 2016.Figure 6
(a) Cash flows of contrarians and followers. Here we setα=0.002, Rm=132. Data resource: quotes of CSI300 Index from Jan 1st 2016 to Dec 31st 2016. (b) Comparison of the average contrarian degree (CD), the contrarian degree of contrarian timers (CDR), and the contrarian degree of followers (CDF).
(a) (b)Turning to the contrarian degree (Figure6(b)), the CDR is always higher than the CDF and follows an inverse trend from that of the CDF and CD. The CDR is at its peak when the CDF reaches its minimum. When the market is in violent oscillation, the polarization of contrarian degree between different investors is quite serious. In other words, the CDR and CDF are closer when the market is gentler. Contrarians are more sensitive to signals of an overheated market than followers, so opportunities for timing arbitrage will become clearer, and contrarians are more willing to take reversal operations when more followers blindly chase the trend. On the other hand, followers are less impetuous when there is no intense trend, and their ambiguous behavior confuses contrarians, in which case, the CDR decreases while the CDF increases, and these two groups become more similar.We last compare the cash flows of contrarians and followers under different years and different proportions of contrarians (Figure7). The four panels all display a polarization of the cash flow at first and then a convergence of the three curves. With an increase in number of contrarians, the cash flow situations of the two groups can converge, which indicates that a homogenous market, in which contrarians cannot be well distinguished from followers, will occur when R/N>25% (an empirical result). If there were a lot of followers, cash would either dump substantially into the stock market (Figures 7(a), 7(b), and 7(d)) or face a large evacuation (Figure 7(c)), whereas the inverse behavior by contrarians could alleviate the situation. As R/N exceeds 25%, the overall market cash flow is maintained at a relatively stable position near zero. Furthermore, the trading behavior of contrarians in a high-CD market is usually the reverse of that in a low-CD market.Figure 7
Changes in average cash flows with an increase ofR/N. The four panels refer to China’s stock market in four different years, and each compares the average cash flows of contrarians and followers.
(a)
2016 (b)
2015 (c)
2008 (d)
2007As a summary, the behavior of followers dominates the trend of China’s stock market prices. But a lot of profitable opportunities are in the hands of contrarians. Contrarians, who usually hold opposite cash flows compared to followers, help to drive distorted prices back to normal levels, especially in extreme markets.


## 4. Conclusion

In this paper, we have considered the Ising model with contrarians and followers. With the model, we have successfully reproduced the pattern of the stock sequence, based on which, the proportion of trading volume caused by contrarians in the real market has been determined.Using data on China’s stock market, we have found that contrarians only contribute to 12-14% of trading volume in the observation period. However, the overall contrarian degree changes significantly over time. Investors are more intended to take contrarian operations in moderately turbulent markets which possess the ability of mean reversion, but less likely to consider contrarian opportunities in extreme unilateral-trend markets. Particularly, we have found that investors in the bear market are generally more emotional than in the bull one. The contrarians are conducive to alleviating the overreaction of the market and promoting the mean reversion and price discovery of the market.Additionally, we have compared the performance of contrarians and followers and found that the greater the volatility of the market, the greater the differentiation of their contrarian degree. This is further reflected in the trend of the cash flow they hold. While the actual return rate sequence is mainly driven by followers, the contrarians hold a lot of profitable opportunities.



---

*Source: 1678086-2019-04-10.xml*