Behavioral agent-based framework for interacting financial markets

Heba M. Ezzat (Department of Socio-Computing, Cairo University, Giza, Egypt)

Review of Economics and Political Science

ISSN: 2631-3561

Article publication date: 3 February 2020

Issue publication date: 19 March 2020

1305

Abstract

Purpose

This paper aims at developing a behavioral agent-based model for interacting financial markets. Additionally, the effect of imposing Tobin taxes on market dynamics is explored.

Design/methodology/approach

The agent-based approach is followed to capture the highly complex, dynamic nature of financial markets. The model represents the interaction between two different financial markets located in two countries. The artificial markets are populated with heterogeneous, boundedly rational agents. There are two types of agents populating the markets; market makers and traders. Each time step, traders decide on which market to participate in and which trading strategy to follow. Traders can follow technical trading strategy, fundamental trading strategy or abstain from trading. The time-varying weight of each trading strategy depends on the current and past performance of this strategy. However, technical traders are loss-averse, where losses are perceived twice the equivalent gains. Market makers settle asset prices according to the net submitted orders.

Findings

The proposed framework can replicate important stylized facts observed empirically such as bubbles and crashes, excess volatility, clustered volatility, power-law tails, persistent autocorrelation in absolute returns and fractal structure.

Practical implications

Artificial models linking micro to macro behavior facilitate exploring the effect of different fiscal and monetary policies. The results of imposing Tobin taxes indicate that a small levy may raise government revenues without causing market distortion or instability.

Originality/value

This paper proposes a novel approach to explore the effect of loss aversion on the decision-making process in interacting financial markets framework.

Keywords

Citation

M. Ezzat, H. (2020), "Behavioral agent-based framework for interacting financial markets", Review of Economics and Political Science, Vol. 5 No. 2, pp. 94-115. https://doi.org/10.1108/REPS-03-2019-0037

Publisher

:

Emerald Publishing Limited

Copyright © 2020, Heba M. Ezzat.

License

Published in Review of Economics and Political Science. Published by Emerald Publishing Limited. This article is published under the Creative Commons Attribution (CC BY 4.0) licence. Anyone may reproduce, distribute, translate and create derivative works of this article (for both commercial and non-commercial purposes), subject to full attribution to the original publication and authors. The full terms of this licence may be seen at http://creativecommons.org/licences/by/4.0/legalcode


1. Introduction

Tobin (1978) argues that imposing small, uniform taxes on all financial transactions would penalize short-term speculations and, hence, stabilize the financial market. Many European Union countries impose taxes on financial transactions. However, introducing financial transaction taxes in other financial markets is still under debate. Proponents believe that a levy of financial transaction taxes would provide sizeable revenues to governments. On the other hand, contrarians argue that introducing transaction taxes to financial markets would reduce market liquidity and a higher price volatility would be ensued. Additionally, the growing role of electronic brokering would increase tax evasion possibilities. This results in reducing the Tobin tax’s ability to yield revenues.

Hesitation of imposing a levy could be due to the unexpected results of market crashes or instability. Collateral effects can be avoided by exploring the impact of regulatory policies on the dynamics of artificial financial markets. The effect of imposing Tobin taxes on the dynamics of artificial financial markets has been studied in many studies (Westerhoff and Dieci, 2006; Westerhoff, 2008; Stanek and Kukacka, 2017). However, none of these studies has considered the effect of behavioral biases on trader’s decision-making process.

The expected utility theory has led the analysis of decision-making under uncertainty. Utility expectations was perceived as a normative model of rational choice (Eiselt and Marianov, 2011) and formulated as a descriptive model of economic behavior (Friedman and Savage, 1948; Neve et al., 2015). Therefore, it was assumed that all rational economic agent would follow the utility theory most of the time. Markowitz (1952) proposes that utility should be defined on gains and losses rather than on final wealth states. Later, Kahneman and Tversky described several choice problems in which preferences under uncertainty violate the axioms of the expected utility theory (Kahneman and Tversky, 1979, 1984, 1991, 1992; Kahneman et al., 1990).

Kahneman and Tversky reveal that risk aversion in the positive domain is associated with risk-seeking in the negative domain; this effect is known as the reflection effect. These propositions establish an alternative description model for decision-making under risk, called the prospect theory. According to the prospect theory, people normally perceive outcomes as gains and losses, instead of final states of wealth. However, gains and losses are defined relative to some reference point, which may correspond to the current wealth position. Additionally, gains and losses could be defined as the actual received or paid amounts.

As proposed by Kahneman and Tversky (1979), a value function for changes of wealth is concave above a reference point and convex below it. Accordingly, the proposed S-shaped value function is defined on deviations from the reference point; concave for gains and convex for losses and steeper for losses than for gains. The main behavior affecting responses to changes in wealth is that the pain of losing a sum of money seems to be greater than the happiness associated with gaining the same amount. These findings have been supported by recent studies (McGraw et al., 2010; Neve et al., 2015).

Few efforts have been spent to introduce behavioral biases to agent-based models (Takahashi and Terano, 2003; Lovric et al., 2010; Li et al., 2014; Selim et al., 2015; Ezzat, 2016; Feldman and Lepori, 2016). For instance, Selim et al. (2015) investigate the effect of loss-aversion behavioral bias on the switching behavior between technical and fundamental trading strategies, market stability and price distortions. The authors study market dynamics under two assumptions:

  1. chartists are loss-neutral; and

  2. chartists are loss-averse.

The results reveal that most of the traders prefer fundamental analysis over technical analysis. Henceforth, loss aversion improves the market by minimizing its volatility and distortion. Nevertheless, the above models are not designed to explore the dynamics of interacting financial markets. Studying the interaction between international financial markets is of crucial importance, especially after the recent global financial crisis (Westerhoff and Dieci, 2006; Schmitt and Westerhoff, 2014).

The main contributions of this paper are:

  • introducing loss-aversion behavioral bias to the framework of interacting financial markets proposed by Westerhoff and Dieci (2006);

  • investigating the dynamics of interaction between two financial markets populated with loss-averse agents; and

  • examining the effect of levying transaction taxes on markets stability, price distortion and the switching behavior between interacting markets following two different trading strategies; fundamental and technical analysis.

The aforementioned models can replicate some important stylized facts, which are common statistical features observed in most financial markets. Significant stylized facts are usually formulated in terms of qualitative and quantitative properties such as price bubbles and market crashes, random-walk prices, clustered volatility, excess volatility and long memory (Mandelbrot, 1963; Fama, 1970; Guillaume et al., 1997; Cont, 2001; Cont, 2005; Haas and Bigorsch, 2011).

A simple behavioral agent-based model of two interacting financial markets is developed. The model is structured as follows. The markets are populated with two types of agents; market makers and traders. At each time step, traders decide either to trade or to stay inactive. Active traders follow technical or fundamental trading strategy as suggested by previous surveys (Taylor and Allen, 1992; Menkhoff, 1997; Frankel and Froot, 1987a, 1987b, 1990) and laboratory experiments (Hommes, 2011). Technical trading aims at exploiting price trends. Conversely, fundamental trading seeks to take advantage of mean reversion. Traders can participate in one market at a time. The attractiveness of a trading strategy is determined by the performance of this strategy in most recent past, which demonstrates a learning behavior. Trading-strategy weights are computed using the discrete-choice model proposed by Manski and McFadden (1981). However, traders following technical analysis are loss-averse, where losses loom larger than equivalent gains. Accordingly, weights of technical trading are expressed in terms of a piecewise linear function proposed by the prospect theory (Kahneman and Tversky, 1979, 1984, 1991, 1992). There is a market maker located in each market. Market makers set asset prices according to the net submitted orders. For this purpose, a linear impact function proposed by Farmer and Joshi (2002) is followed. Agents interact indirectly through their influence on price adjustment. This affects the attractiveness of trading rules, which turns to affect the belief adaptation process.

By simulation, the results show that the developed model can generate financial time series that exhibit important stylized facts observed empirically such as bubbles and crashes, volatility clustering, power-law tails, long memory and fractal structures. Thereafter, the proposed model serves as a test-bed for policy makers to investigate the effect of levying taxes on financial transaction. The impact of levying financial transaction taxes on the market dynamics is extensively investigated.

The rest of the paper is organized as follows. In Section 2, the proposed agent-based financial market model is presented. Asset pricing dynamics is investigated in Section 3. Furthermore, the results of extensive Monte Carlo simulation are displayed. In Section 4, the effect of imposing transaction taxes on market dynamics is investigated. Section 5 concludes the paper.

2. The model

There are two different stock markets, Market X and Market Z, located in two countries. It is assumed that the countries either share the same currency or have agreed upon a fixed exchange rate. For simplicity, the two stock markets are assumed to be symmetric. Thereby, traders have no preference for one market over the other. There are two types of agents; market makers and traders. In each time step t, t = 0, 1, […], T, each trader decides either to submit orders or abstain from the market. If a trader chooses to submit an order, she/he can submit her/his order either to Market X or Market Z. In addition, the trader can follow either technical or fundamental trading rule. Therefore, if the trader decides to submit an order, she/he would choose between five trading alternatives (two different stock markets and three different trading actions).

Market makers settle asset prices following a log-linear price impact function suggested by Farmer and Joshi (2002). This function measures the relation between the orders quantity (demand/supply) and the price of the asset. Thus, asset log price in period t + 1 for Markets X and Z, can be given by:

(1) pt+1X=ptX+a(wtXcDtXc+wtXfDtXf)+αtX,
and:
(2) pt+1Z=ptZ+a(wtZcDtZc+wtZfDtZf)+αtZ,
where ptX and ptZ are the log prices at time t in Markets X and Z, respectively, a is a positive price settlement parameter, DtXc and DtZc are the orders submitted at time t by chartists to Markets X and Z, respectively, DtXf and DtZf are the orders submitted at time t by fundamentalists to Markets X and Z, respectively, wtXc and wtXf are the weights of technical and fundamental strategy, respectively, in Market X at time t, and wtZc and wtZf are the weights of chartists and fundamentalists, respectively, in Market Z at time t. To make the assumptions close to the real markets, noise terms αtX and αtZ are added to catch any random factors affecting the price settlement process in Markets X and Z, respectively. It is assumed that αtX and αtZ, t = 1, 2, […], T are independent, identically distributed (IID) normally distributed random variables with mean zero and constant standard deviations σαX and σαZ, respectively.

Chartists follow technical analysis to exploit price changes (Murphy, 1999). Technical trading orders submitted to Markets X and Z, respectively, at time t can be written as:

(3) DtXc=b(ptXpt1X)+βtX,
and:
(4) DtZc=b(ptZpt1Z)+βtZ,
where b is a positive reaction parameter (also called extrapolating parameter) that captures the sensitivity of chartists to price changes. The first term at the right-hand side of equations (3) and (4) represents the difference between the current and last price, which indicates the exploitation of price changes. The second term captures additional random orders of technical trading rules. βtX and βtz,t=1,2,,T are IID normally distributed random variables with mean zero and constant standard deviation σβX and σβZ, respectively.

Fundamental analysis assumes that prices will revert to their fundamentals in the short run (Graham and Dodd, 2009). Orders submitted by fundamentalists to Markets X and Z at time t can be descried by:

(5) DtXf=c(ftXptX)+γtX,
and:
(6) DtZf=c(ftZptZ)+γtZ,
where c is a reaction parameter (also called a reverting parameter) that captures the sensitivity of fundamentalists to price mean reversion. ftX and ftZ are log-fundamental values (or simply fundamental values) (Day and Huang, 1990). The first term at the right-hand side of equations (5) and (6) represents market distortion at time t, which computes the deviation of index prices from their fundamentals, distt = ftpt. γtX and γtZ are introduced to capture additional random orders of fundamental trading rules. γtX and γtZ,t=1,2,,T are IID normally distributed random variables with mean zero and constant standard deviations σγX and σγZ, respectively. The log-fundamental values are assumed to evolve following a random walk such that:
(7) ftX=ft1X+ηtX
and:
(8) ftZ=ft1Z+ηtZ,
where ηtX and ηtZ are fundamental shock values in Markets X and Z, respectively. ηtX and ηtZ,t=1,…,T are IID normally distributed with mean zero and constant standard deviations σ X and σ Z , respectively. It is assumed that fundamental volatilities are equal in both markets. It is also assumed that fundamental traders can calculate the fundamental values.

The evolutionary part of the model depicts how beliefs are evolving over time (Brock and Hommes, 1998). That is, how agents adapt their beliefs and switch between strategies. Belief adaptation is mirrored in the strategy weights wt;wt={wtXc,wtZc,wtXf,wtZf,wt0}, where wt0 represents the weight of inactive agents and wtXc,wtZc,wtXf,wtZf are as indicated in equations (1) and (2). Strategy weights are updated according to evolutionary fitness measures (or attractiveness of the trading rules) which can be presented as:

(9) AtXc=(exp(ptX)exp(pt1X))Dt2XctaxX(exp(ptX)exp(pt1X))|Dt2Xc| + mAt1Xc,
(10) AtXf=(exp(ptX)exp(pt1X))Dt2XftaxX(exp(ptX)exp(pt1X))|Dt2Xf|     + mAt1Xf,
(11) AtZc=(exp(ptZ)exp(pt1Z))Dt2ZctaxZ(exp(ptZ)exp(pt1Z))|Dt2Zc|+mAt1Zc,
(12) AtZf=(exp(ptZ)exp(pt1Z))Dt2ZftaxZ(exp(ptZ)exp(pt1Z))|Dt2Zf|+mAt1Zf,
and:
(13) At0=0,
where AtXc, AtZc, AtXf, AtZf and At0 are the fitness measures of following chartist strategy in Market X, chartist strategy in Market Z, fundamental strategy in Market X, fundamental strategy in Market Z and no-trade strategy, respectively. Inactive traders got zero attractiveness for abstaining from trading. The fitness measure of the other two trading rules, the technical and the fundamental analysis, depends on three components. The first term of the right-hand sides of equations (9)-(12) is the performance of the strategy rule in the most recent time. Notice that orders submitted in period t – 2 are executed at the price declared in period t – 1. Gains or losses are recognized according to prices announced in period t. The second term of the right-hand side of equations (9)-(12) represents the costs of trading in terms of transaction taxes, where taxX is the tax rate of Market X and taxz is the tax rate of Market Z. The third term of the right-hand side of equations (9)-(12) denotes agents’ memory, where 0 ≤ m ≤ 1 is the memory parameter that measures the speed of recognizing current myopic profits.

Loss-aversion behavioral bias is proposed, inspired by Selim et al. (2015), where chartists evaluate their strategy fitness in terms of a value function of gains and losses (Tversky and Kahneman, 1991; Benartzi and Thaler, 1993). The proposed value function implies that the pain of losses is twice the satisfaction of equivalent gains. Therefore, the attractiveness of technical strategy is given by:

(14) vtXc={AtXcifAtXc0λAtXcifAtXc<0,
(15) vtZc={AtZc   ifAtZc0λAtZc  ifAtZc<0,
where λ > 1 is the parameter of loss aversion that measures the relative sensitivity to gains and losses. However, setting λ = 1 reduces the value functions to vtXc=AtXc and vtZc = AtZc; this case can be called loss-neutral chartists (Selim et al., 2015).

Following Manski and McFadden (1981), the weight of each strategy can be obtained by the discrete-choice model as:

(16) wtXc=exp(rvtXc)1+exp(rvtXc)+exp(rAtXf)+exp(rvtZc)+exp(rAtZf),
(17) wtXf=exp(rAtXf)1+exp(rvtXc)+exp(rAtXf)+exp(rvtZc)+exp(rAtZf),
(18) wtZc=exp(rvtZc)1+exp(rvtXc)+exp(rAtXf)+exp(rvtZc)+exp(rAtZf),
(19) wtZf=exp(rAtZf)1+exp(rvtXc)+exp(rAtXf)+exp(rvtZc)+exp(rAtZf),
and:
(20) wt0=1wtXcwtZcwtXfwtZf.

Trading strategy weights are proportional to strategy attractiveness. Parameter r in equations (16)-(19) is called the intensity of choice, and it measures the agent’s sensitivity to select the trading strategy with higher fitness measure.

3. Simulation results and analyses

3.1 Calibration and simulation design

In this section, the model is validated by investigating the extent to which it is able to replicate the stylized facts observed empirically. The values of model parameters are chosen such that the model can mimic the dynamics of real financial markets. For the detailed declaration of the idea behind choosing specific values of the parameters, the reader can refer to Westerhoff and Dieci (2006).

The proposed artificial financial market is implemented using NetLogo platform (Unsupported source type (ElectronicSource) for source Wilensky, 1999). At initialization, all parameters of the model are equal to the values defined in Table I. The performance of 1,000 simulation runs is investigated. Each run contains 5,000 daily observations. In the following, the evolutionary dynamics of the proposed model are discovered.

3.2 Stylized facts replication

Before engaging in a comprehensive Monte Carlo simulation, it is important first to observe a representative simulation run. Figures 1-8 depict the behavior of this specific run. Figure 1 illustrates the evolution of log-prices for the two markets. Note that the prices oscillate around their fundamental values. The average market distortion can be computed as dist=1Tt=1T|distt|, which exhibits a value of 11.49 per cent for distX and a value of 8.54 per cent for distZ. The two price series are random walk and display bubbles and crashes. These results are in good agreement with the stylized facts observed empirically.

Figure 2 displays returns of the two markets. It can be observed that extreme returns reach up to ± 20 and ± 10 per cent for Market X and Z, respectively. Following Guillaume et al. (1997), volatility can be calculated as the average absolute returns (vol) vol=1Tt=1T|rt|. The computed average volatilities are 1.35 and 1.07 per cent for volX and volZ, respectively, indicating excess volatility feature (Shiller, 1981). Also, Figure 2 shows another stylized fact of asset markets, which is volatility clustering.

Figure 3 depicts the weights of the five trading strategies. The first panel in Figure 3 displays the average weights, which are computed as 20, 25.6, 19.2, 20.4 and 14.8 per cent for wtXc, wtXf, wt0, wtZf and wtZc, respectively. Note the higher volatility in Market X than that in Market Z, which can be explained by the higher participation of chartists in Market X than that in Market Z. Additionally, these results show that 34.8 (46) per cent of the agents follow technical (fundamental) trading. The effect of loss-aversion behavioral bias can be explored by running a simulation using the same random seeds and the parameter setting illustrated in Table I except for λ = 1. Differences in the dynamics are merely due to loss-aversion behavior. The second panel in Figure 3 depicts the average weights, which are computed as 22.9, 17.2, 17.5, 18.7 and 23.6 per cent for wtXc, wtXf, wt0, wtZf and wtZc, respectively. Henceforth, 46.5 (35.9) per cent of the agents follow technical (fundamental) trading. Accordingly, loss aversion causes agents to prefer fundamental trading over technical trading. The increased shares of chartists come at the cost of increased market volatilities, which are computed as 1.38 and 1.11 per cent for volX and volZ, respectively.

However, the results of 1,000 simulation runs using different random seeds and the parameter setting displayed in Table I reveal that the mean of average weights is estimated as 17 per cent for wtXc, 23 per cent for wtXf, 20 per cent for wt0, 23 per cent for wtZf and 17 per cent for wtZc. Thereafter, 34 per cent of the agents follow technical trading. Moreover, 46 per cent of the agents preferred fundamental trading. As the two markets are assumed to be symmetric, chartists and fundamentalists are equally participated in both markets. Subsequently, no market is preferred over the other. In addition, the reduction in technical trading can be due to the loss-aversion behavior.

Another significant stylized fact is power-law tails, with a tail index somewhere in the region 2-5. The exponent α of the Pareto distribution for the tails can be expressed by the following inverse cubic law:

(21) Prob(|rt|>x) ∼ xαr,
with αr ≈ 3 (Lux and Marchesi, 1999; Lux, 2009; Haas and Bigorsch, 2011). To check the power-law tails, the Hill index tail estimate is calculated for the smallest and largest 10 per cent of the observations. Figure 4 illustrates the Hill index tails estimation process (Hill, 1975; Huisman et al., 2001). Regression on the smallest (largest) 10 per cent of the observations yields a value of 2.85 ± 0.049 (2.40 ± 0.048) for Market X and a value of 4.09 ± 0.079 (3.51 ± 0.072) for Market Z. These results are in good accordance with the inverse cubic law of (21).

Another astonishing stylized fact to be investigated is the absence of autocorrelation in raw returns. Figure 5 represents autocorrelations for the first 100 lags of raw returns for both markets. The dashed lines present 95 per cent confidence bands according to the assumption of a white noise process. The raw returns for the two markets show autocorrelation coefficients, which are not significant over 100 lags. This implies the randomness of asset prices.

To study the predictability of asset volatility, autocorrelation in absolute returns is studied. The two panels in Figure 6 depict autocorrelations for the first 100 lags of absolute returns for the two markets. The dashed lines present 95 per cent confidence bands according to the assumption of a white noise process. The panels show that absolute returns are significantly autocorrelated for up to 100 (30) lags in Market X (Z). Thus, volatility can be partially predicted (with no significant prediction of the direction of price movements).

Another important fact of the financial markets is self-similarity as recognized by Mandelbrot (1983). To investigate self-similarity, detrended fluctuation analysis (DFA) is performed following Peng et al. (1994). Linear relationship on a log-log scale between the average fluctuation, Fn, and the time scale, n, shows scaling structure of asset returns. Figure 7 depicts the estimation of the scaling exponent, Hr, for raw returns of Markets X and Z. A value of H = 0.5 indicates a white-noise process, a value of 0.5 < H < 1 corresponds to long-range power-law autocorrelations and a value of 0 < H < 0.5 indicates that large and small oscillations of the time series are very likely to alternate. The scaling exponent Hr yields a value of 0.50 ± 0.029 for Market X and a value of 0.52 ± 0.005 for Market Z. Consequently, estimated values of the scaling exponent show white-noise processes.

Figure 8 presents the estimation of the scaling exponent, H|r|, for absolute asset returns. The scaling exponent H|r| yields a value of 0.89 ± 0.090 for Market X and a value of 0.73 ± 0.068 for Market Z. Estimated values of the scaling exponent indicate long-range power-law autocorrelations in absolute returns.

Thereafter, the simulation run illustrated in Figures 1-8 imitates the behavior observed in real financial markets remarkably well. In what follows, the robustness of these results is investigated by performing a thorough Monte Carlo analysis. The analysis relies on 1,000 simulation runs, each comprising 5,000 observations. All simulation runs are executed with the parameter setting offered in Table I using different seeds of the random variables.

Table II reports estimates of the mean and median of the mean, maximum, minimum, standard deviation, skewness and kurtosis for the two markets. Estimates of the mean and the median of the kurtosis for the two return series are all greater than 3, indicating leptokurtosis.

Table III illustrates estimates of the mean and the median of the Hill tail index estimators α^k for k ∈ {2.5, 5, 10} {2.5, 5, 10} per cent of the smallest (left tail) and largest (right tail) returns for the two assets. For example, considering the smallest (largest) 5 per cent of observations of rX, estimate of the tail index displays a value of 3.63 (3.09) for the median. The results show that the average Hill tail index estimates of the largest and smallest 10 per cent observations are in good agreement with the universal cubic law (see (21)).

Table IV displays estimates of the mean and the median of autocorrelation in raw returns, ACr, for lags ℓ ∈ {1,2,3}∈, and autocorrelation in absolute returns, AC|r|, for lags ℓ ∈ {1, 20, 50,100}. Estimates of the median of autocorrelation coefficients ACr indicate that price changes are mainly uncorrelated. For instance, the estimate of the median of autocorrelation coefficients ACr1 reveals a value of 0.03 for rX and a value of 0.03 for rZ. This is in line with most real financial markets, where asset price evolves according to a random walk. Estimate of the median of autocorrelation coefficients AC|r|1 reveals a value of 0.28 for rX and a value of 0.28 for rZ, indicating persistence in volatility.

Finally, the robustness of the scaling behavior and fractal structure is needed to be checked. Table V displays the estimates of the mean and the median for the scaling exponent of raw returns, Hr, and the scaling exponent of absolute returns, H|r|. Estimate of the median of Hr reveals a value of 0.50 for rX and a value of 0.49 for rZ. These figures indicate a small degree for predicting asset returns. Furthermore, estimate of the median of H|r| reveals a value of 0.79 for rX and a value of 0.78 for rZ. These values display long-range power-law autocorrelations in absolute returns.

Summing up, the model replicates the stylized facts of real financial markets remarkably well. Thereafter, the model can serve as a testbed to examine the effect of levying transaction taxes on the agents’ switching behavior. For this purpose, two scenarios are to be investigated. First, the impact of imposing taxes in one market only. Second, the impact of imposing taxes in the two markets. The results of these scenarios are illustrated in the following section.

4. The dynamics with transaction taxes

4.1 Transaction taxes in one market

To explore the impact of imposing transaction taxes in one market only, a transaction tax of 0.25 per cent is imposed in one market, e.g. Market X (as the two markets are assumed to be symmetric, the results would not be changed if Market Z is selected). Figure 9 displays a simulation run using the same random seeds for the simulation presented in Figures 1-8. The simulation is executed based on the parameter setting presented in Table I, except for taxX = 0.0025. Thereafter, differences in the dynamics are merely due to taxation. Figure 9 can be compared directly with Figures 1, 2 and the first panel in Figure 3. The first two panels in Figure 9 show evolution of the log prices. Price bubbles and market crashes can be observed. Moreover, prices oscillate around their fundamentals. The third and fourth panels in Figure 9 show asset returns. The return series exhibit excess volatility and clustered volatility as observed in real financial markets. The last panel in Figure 9 illustrates the weights of the five trading strategies. No trading strategy dominates the others. Surprisingly, the average weights are computed as 20, 25.6, 19.2, 20.4 and 14.8 per cent for wtXc, wtXf, wt0, wtZf and wtZc, respectively. Additionally, the computed average volatilities are 1.35 and 1.07 per cent for volX and volZ, respectively, and the computed average market distortions are 11.49 and 8.54 per cent for distX and distZ, respectively. These are the same figures obtained from the simulation run presented in Figures 1-8. Thereafter, levying taxes in one market does not affect market dynamics in both markets.

To check the robustness of these results, a comprehensive Monte Carlo analysis is applied. The analysis relies on 1,000 simulation runs for each tax rate, which is increased from 0.05 to 0.5 in 20 steps. Each simulation is comprised of 5,000 observations. All simulation runs are executed based on the parameter setting offered in Table I using different seeds of the random variables. Figure 10 depicts the results of the Monte Carlo simulation for the first scenario. Figure 10 displays the average volatility for both markets, average price distortion for both markets and average weights of the five trading strategies. The first panel in Figure 10 depicts that volatility of both markets fluctuate around 1.18 per cent. Which tax rate would stabilize the markets? There is no specific tax rate that would decrease volatility in both markets at the same period. However, there is no tax rate that cause drastic increase in market volatility. The same result is observed from the second panel in Figure 10. No significant deviation in market distortion can be noticed. The last panel in Figure 10 indicate the weights of trading strategies, which are around 46, 34 and 20 per cent for fundamentalists, chartists and inactive traders, respectively, in both markets. In addition, chartists and fundamentalists are almost equally participated in both markets. Thereby, imposing transaction taxes in one market may not affect market stability or price distortion. Moreover, there is no strong evidence that traders would prefer trading in the market without transaction taxes. The traders also prefer fundamental trading over technical trading. However, this is the same result obtained from the model without introducing transaction taxes.

4.2 Transaction taxes in both markets

To explore the impact of imposing transaction taxes in the two markets, a transaction tax of 0.25 per cent is imposed in both markets. Figure 11 displays a simulation run based on the same random seeds of the simulation run depicted in Figures 1-8 using the parameter setting presented in Table I, except for taxX = 0.0025 and taxZ = 0.0025. Thereby, differences in the dynamics are only due to taxation. Figure 11 can be compared directly with Figures 1, 2 and the first panel in Figure 3. The first two panels in Figure 11 depict log-price evolution. The prices oscillate around their fundamentals and resemble the behavior of asset prices observed empirically. The third and fourth panels in Figure 11 illustrate asset returns, which exhibit excess volatility and volatility clustering as observed in real financial markets. The last panel in Figure 11 illustrates the weights of the five trading strategies. Amazingly, the average weights are computed as 20, 25.6, 19.2, 20.4 and 14.8 per cent for wtXc, wtXf, wt0, wtZf, and wtZc, respectively. Additionally, the computed average volatilities are 1.35 and 1.07 per cent for volX and volZ, respectively. The computed average market distortions are 11.49 and 8.54 per cent for distX and distZ, respectively. These are the same figures obtained from the simulation run presented in Figures 1-9. Thereafter, levying taxes in the two interacting markets does not affect market dynamics in both markets.

The robustness of these results is checked by applying a thorough Monte Carlo analysis. The analysis relies on 1,000 simulation runs for each tax rate, which is increased from 0.05 to 0.5 in 20 steps. Each simulation is comprised of 5,000 observations. All simulation runs are executed based on the parameter setting offered in Table I using different random seeds. Figure 12 depicts the results of the Monte Carlo simulation for the second scenario. Figure 12 shows average volatility for both markets, average price distortion for both markets and average weights of the five trading strategies. The first panel in Figure 12 depicts that volatility of both markets fluctuate around 1.18 per cent. In addition, different values of tax rates have slight effect on market volatilities in either direction. The same result is obtained for price distortions. No significant deviation in market distortion can be noticed from the second panel in Figure 12. As indicated by the last panel in Figure 12, the weights of trading strategies are around 46, 34 and 20 per cent for fundamentalists, chartists and inactive traders, respectively, in both markets. Furthermore, chartists and fundamentalists are almost equally participated in the two markets. Thus, imposing transaction taxes in two interacting markets may not cause instability or price distortion in both markets. Moreover, the traders prefer fundamental trading over technical trading. Nevertheless, this is the same result obtained in the artificial markets with zero taxes and with a levy in one market only.

It should be noted that the key difference between the proposed model and the model provided by Westerhoff and Dieci (2006) is the loss-aversion behavioral bias. Westerhoff and Dieci (2006) find that imposing Tobin taxes in one market will result in stabilizing this market at the cost of the other market’s stability. Additionally, levying Tobin taxes in the two markets decreases volatility and distortion in both markets. The above authors report the average weight of 38, 45 and 17 per cent for fundamentalists, chartists and inactive traders, respectively. Note that the main assumptions and parameter values followed in this research are similar to those of Westerhoff and Dieci (2006), except for the loss-aversion behavior. Thereby, the difference in results can mainly be attributed to loss-aversion behavior, which stabilizes the market by managing the speculative behavior. Additionally, governments could levy small transaction taxes to generate extra revenues without worrying about market stability.

5. Conclusions

In this paper, a behavioral agent-based model is proposed to provide a suitable testbed for policy makers. The proposed framework models the interaction between two different financial markets; Market X and Market Z. There are two types of agents populating the artificial markets; traders and market makers. Each time step, traders decide on one of the trading strategies:

  • technical trading in Market X;

  • fundamental trading in Market X;

  • technical trading in Market Z;

  • fundamental trading in Market Z; or

  • abstain from trading.

The weight of each trading strategy is determined according to past and current performance of this strategy. As chartists are loss-averse, losses loom larger than equivalent gains. The discrete-choice model is followed to compute the weights of trading strategies. Market makers update asset prices according to the net submitted orders. A log-linear price impact function is followed to settle asset prices. The proposed model can replicate stylized facts observed empirically such as bubbles and crashes, excess volatility, volatility clustering, absence of autocorrelation in raw returns, persistence in volatility, power-law tails and fractal structures. Thereby, the model can be used as a test-bed to investigate the effect of applying regulatory policies. Furthermore, loss-aversion behavioral bias affects agent switching behavior among trading strategies, which consequently enhances market stability. This can be explained as follows. The increase in price distortion causes the chartists to become aggressive. The increasing switching behavior to technical strategy will increase market volatility. As the distortion approaches its maximum value, traders perceive fundamental analysis as the most appealing strategy to follow. The increasing switch to the fundamental analysis will drag asset prices to their fundamentals and reduce market volatility and price distortion. Tobin transaction tax is introduced and its impact on market dynamics is explored. For this purpose, two scenarios are considered:

  1. levying a transaction tax in one market only; and

  2. levying transaction taxes in the two markets.

The results show that imposing transaction taxes in either scenario would affect weights of trading strategies, distortion or volatility. As loss aversion manages the speculative behavior, imposing transaction taxes in markets populated with loss-averse chartists may not affect market stability and price distortions. Thereafter, imposing small transaction taxes would generate revenues and may not affect market dynamics. The results are in good agreement with Tobin’s suggestions.

Figures

Evolution of log-prices for the two markets

Figure 1.

Evolution of log-prices for the two markets

Returns of the two markets

Figure 2.

Returns of the two markets

Weights of trading strategies

Figure 3.

Weights of trading strategies

The estimated Hill tail index for the two markets

Figure 4.

The estimated Hill tail index for the two markets

Autocorrelation in raw returns of the two markets

Figure 5.

Autocorrelation in raw returns of the two markets

Autocorrelation in absolute returns of the two markets

Figure 6.

Autocorrelation in absolute returns of the two markets

Estimation of self-similarity parameter for raw returns of the assets

Figure 7.

Estimation of self-similarity parameter for raw returns of the assets

Estimation of self-similarity parameter for absolute returns of the two return series

Figure 8.

Estimation of self-similarity parameter for absolute returns of the two return series

The impact of imposing a transaction tax of 0.25 per cent in market X on both markets’ log prices, asset returns and weights of trading strategies

Figure 9.

The impact of imposing a transaction tax of 0.25 per cent in market X on both markets’ log prices, asset returns and weights of trading strategies

The impact of imposing taxes in market X on the dynamics of the two markets

Figure 10.

The impact of imposing taxes in market X on the dynamics of the two markets

The impact of levying a transaction tax of 0.25 per cent in markets X and Z on both markets’ log prices, asset returns and the weights of trading strategies

Figure 11.

The impact of levying a transaction tax of 0.25 per cent in markets X and Z on both markets’ log prices, asset returns and the weights of trading strategies

The impact of imposing taxes in markets X and Z on the dynamics of the two markets

Figure 12.

The impact of imposing taxes in markets X and Z on the dynamics of the two markets

Parameters for the simulation of the two interacting financial markets under loss-aversion behavioral bias

Parameter Value Description of parameter
a 1 Price settlement parameter
b 0.05 Extrapolating parameter
c 0.05 Reverting parameter
m 0.975 Memory parameter
r 300 Intensity of choice parameter
λ 2.5 Loss aversion parameter
taxX 0 Tax rate of Market X
taxZ 0 Tax rate of Market Z
σαX 0.01 Standard deviation of the random factors affecting the price settlement process in Market X
σαZ 0.01 Standard deviation of the random factors affecting the price settlement process in Market Z
σβX 0.05 Standard deviation of the additional random orders of technical trading orders submitted to Market X
σβZ 0.05 Standard deviation of the additional random orders of technical trading orders submitted to Market Z
σγX 0.01 Standard deviation of the additional random orders of fundamental trading orders submitted to Market X
σγZ 0.01 Standard deviation of the additional random orders of fundamental trading orders submitted to Market Z

Descriptive statistics for asset returns of the two markets

Market Mean/median Mean Minimum Maximum SD Skewness Kurt
X Mean 3.35 * 10−6 −0.11 0.11 0.02 0.00 3.89
Median −5.62 * 10−6 −0.11 0.11 0.02 0.01 3.64
Z Mean 1.49 * 10−6 −0.11 0.11 0.02 0.00 3.84
Median 3.09 * 10−6 −0.11 0.11 0.02 0.00 3.55
Notes:

The table reports the estimates of the mean and the median of the mean, maximum, minimum, standard deviation, skewness and kurtosis; computations are based on 1,000 time series, each containing 5,000 observations

The Hill tail index estimator) α^k for the left and right tails

Asset Mean/median Left-tail exponent Right-tail exponent
α^2.5% α^5% α^10% α^2.5% α^5% α^10%
rX Mean 3.55 3.60 3.50 2.79 3.18 3.37
Median 3.56 3.63 3.35 2.79 3.09 3.21
rZ Mean 3.57 3.62 3.51 2.79 3.19 3.39
Median 3.60 3.63 3.39 2.78 3.13 3.25
Notes:

The table reports the estimates of the mean and the median of the Hill tail index estimators) α^k for k ∈ {2.5, 5, 10} per cent of the smallest (left-tail) and largest (right-tail) returns of the two markets; computations are based on 1,000 time series, each containing 5,000 observations

Autocorrelations for raw and absolute returns of both markets

Asset Mean/median ACr1 ACr2 ACr3 AC|r|1 AC|r|20 AC|r|50 AC|r|100
rX Mean 0.09 0.07 0.07 0.32 0.22 0.13 0.07
Median 0.03 0.01 0.01 0.28 0.17 0.09 0.02
rZ Mean 0.03 0.01 0.01 0.27 0.17 0.08 0.02
Median 0.03 0.01 0.01 0.28 0.17 0.08 0.02
Notes:

The table displays the estimates of the mean and the median of the autocorrelation in raw returns, ACr, for lags ℓ ∈ {1,2,3}, and the autocorrelation in absolute returns, AC|r|,for lags ℓ ∈ {1,20,50,100}; computations are based on 1,000 time series, each containing 5,000 observations

Scaling exponent for raw and absolute returns of the two markets

Measures of central tendency rX rZ
Hr H|r| Hr H|r|
Mean 0.50 0.78 0.50 0.78
Median 0.50 0.79 0.49 0.78
Notes:

Estimates of the mean and the median of the scaling exponent of raw returns, Hr, and the scaling exponent of absolute returns, H|r|; computations are based on 1,000 time series, each containing 5,000 observations

References

Benartzi, S. and Thaler, R.H. (1993), “Myopic loss aversion and the equity premium puzzle”, National Bureau of Economic Research, No. w4369, pp. 1-32.

Brock, W. and Hommes, C. (1998), “Heterogeneous beliefs and routes to chaos in a simple asset pricing model”, Journal of Economic Dynamics and Control, Vol. 22 Nos 8/9, pp. 1235-1274.

Cont, R. (2001), “Empirical properties of asset returns: stylized facts and statistical issues”, Quantitative Finance, Vol. 1 No. 2, pp. 223-236.

Cont, R. (2005), “Long range dependence in financial markets: new trends in theory and applications”, in Lévy-Véhel, J. and Lutton, E. (Eds) Fractals in Engineering, Springer, London.

Day, R. and Huang, W. (1990), “Bulls, bears, and market sheep”, Journal of Economic Behavior and Organization, Vol. 14 No. 3, pp. 299-329.

Eiselt, H.A. and Marianov, V. (2011), “Decision making with multiple criteria and uncertainty”, 2011 International Conference on Software and Computer Applications, IPCSIT, pp. 165-167.

Ezzat, H.M. (2016), “On agent-based modelling for artificial financial markets”, PhD thesis, Department of Social Science Computing, Cairo.

Fama, E.F. (1970), “Efficient capital markets: a review of theory and empirical work”, The Journal of Finance, Vol. 25 No. 2, pp. 383-417.

Farmer, J. and Joshi, S. (2002), “The price dynamics of common trading strategies”, Journal of Economic Behavior and Organization, Vol. 49, pp. 149-171.

Feldman, T. and Lepori, G. (2016), “Asset price formation and behavioral biases”, Review of Behavioral Finance, Vol. 8 No. 2, pp. 137-155.

Frankel, J. and Froot, K. (1987a), “Understanding the dollars in the eighties: rates of return, risk premiums, speculative bubbles, and chartists and fundamentalists”, Center for Economic Policy Research, No. 169, pp. 1-62.

Frankel, J. and Froot, K. (1987b), “Using survey data to test standard propositions regarding exchange rate expectations”, American Economic Review, Vol. 77, pp. 133-153.

Frankel, J. and Froot, K. (1990), “Chartists, fundamentalists and the demand for dollars”, NBER Working Paper No. r1655, pp. 73-126.

Friedman, M. and Savage, L. (1948), “The utility analysis of choices involving risk”, Journal of Political Economy, Vol. 56 No. 4, pp. 279 -304.

Graham, B. and Dodd, D. (2009), Security Analysis, 6th ed., McGraw-Hill Companies, New York, NY.

Guillaume, D., Dacorogna, M. and Dav´e, R. (1997), “From the bird’s eye to the microscope: a survey of new stylized facts of the intra-daily foreign exchange markets”, Finance and Stochastics, Vol. 1 No. 2, pp. 95-129.

Haas, M. and Bigorsch, C. (2011), “Financial economics, fat-tailed distributions”, in Meyers, R. (Ed.) Complex Systems in Finance and Econometrics, Springer, New York, NY.

Hill, B. (1975), “A simple general approach to inference about the tail of a distribution”, The Annals of Statistics, Vol. 3 No. 5, pp. 1163 -1174.

Hommes, C. (2011), “The heterogeneous expectations hypothesis: some evidence from the lab”, Journal of Economic Dynamics and Control, Vol. 35 No. 1, pp. 1-24.

Huisman, R., Koedijk, K., Kool, C. and Palm, F. (2001), “Tail-index estimates in small samples”, Journal of Business and Economic Statistics, Vol. 19 No. 1, pp. 208-216.

Kahneman, D. and Tversky, A. (1979), “Prospect theory: an analysis of decision under risk”, Econometrica, Vol. 47 No. 2, pp. 263-292.

Kahneman, D. and Tversky, A. (1984), “Choices, values and frames”, American Psychologist, Vol. 39 No. 4, pp. 341-350.

Kahneman, D., Knetsch, J. and Thaler, R. (1990), “Experimental tests of the endowment effect and the Coase theorem'”, Journal of Political Economy, Vol. 98 No. 6, pp. 1325-1348.

Li, B., Shang, W., Li, H., Huo, L. and Xu, S. (2014), “Disposition effect in an agent-based financial market model”, Procedia Computer Science, Vol. 31, pp. 680-690.

Lovric, M., Kaymak, U. and Spronk, J. (2010), “Modeling investor sentiment and overconfidence in an agent-based stock market”, Human Systems Management, Vol. 29 No. 2, pp. 89-101.

Lux, T. (2009), “Stochastic behavioral asset pricing models and stylized facts”, in Hens, T. and Schenk-Hoppe, K. (Eds) Handbook of Financial Markets Dynamics and Evolution, Elsevier, North-Holland.

Lux, T. and Marchesi, M. (1999), “Scaling and criticality in a stochastic multi-agent model of a financial market”, Nature, Vol. 397 No. 6719, pp. 498-500.

McGraw, A., Larsen, J. and Kahneman, D. (2010), “Comparing gains and losses”, Psychological Science, Vol. 21 No. 10, pp. 1438-1445.

Mandelbrot, B. (1963), “The variation of certain speculative prices”, The Journal of Business, Vol. 36 No. 4, pp. 394-413.

Mandelbrot, B.B. (1983), The Fractal Geometry of Nature, Macmillan, New York.

Manski, C. and McFadden, D. (1981), Structural Analysis of Discrete Data with Econometric Applications, MIT Press, Cambridge, MA.

Markowitz, H. (1952), “The utility of wealth”, Journal of Political Economy, Vol. 60 No. 2, pp. 151-158.

Menkhoff, L. (1997), “Examining the use of technical currency analysis”, International Journal of Finance and Economics, Vol. 2 No. 4, pp. 307-318.

Murphy, J.J. (1999), Technical Analysis of the Financial Markets: A Comprehensive Guide to Trading and Application, Murphy, J.J. (Ed.), Institute of Finance, New York, NY.

Neve, J., Keulenaer, F., Kavetsos, G., Ward, G., Landeghem, B. and Norton, M. (2015), “The asymmetric experience of positive and negative economic growth: global evidence using subjective well-being data”, CEP Discussion Paper No 1304, pp. 1-36.

Peng, C., Buldyrev, S., Halvin, S., Simons, M., Stanley, H. and Goldberger, A. (1994), “Mosaic organization of DNA nucleotides”, Physical Review E, Vol. 49 No. 2, pp. 1685-1689.

Schmitt, N. and Westerhoff, F. (2014), “Speculative behavior and the dynamics of interacting stock markets”, Journal of Economic Dynamics and Control, Vol. 45, pp. 262-288.

Selim, K.S., Okasha, A. and Ezzat, H.M. (2015), “Loss aversion, adaptive beliefs, and asset pricing dynamics”, Advances in Decision Sciences, Vol. 2015, pp. 1-18.

Shiller, R. (1981), “Do stock prices move too much to be justified by subsequent changes in dividends?”, The American Economic Review, Vol. 71 No. 3, pp. 421-436.

Stanek, F. and Kukacka, J. (2017), “The impact of the Tobin tax in a heterogeneous agent model of the foreign exchange market”, Computational Economics, Vol. 51 No. 1, pp. 1-28.

Takahashi, H. and Terano, T. (2003), “Agent-based approach to investors' behavior and asset price fluctuation in financial markets”, Journal of Artificial Societies and Social Simulation, Vol. 6 No. 3, pp. 1-27.

Taylor, M. and Allen, H. (1992), “The use of technical analysis in the foreign exchange market”, Journal of International Money and Finance, Vol. 11 No. 3, pp. 304-314.

Tobin, J. (1978), “A proposal for international monetary reform”, Eastern Economic Journal, Vol. 4, pp. 153-159.

Tversky, A. and Kahneman, D. (1991), “Loss aversion in riskless choice: a reference-dependent model”, The Quarterly Journal of Economics, Vol. 107 No. 4, pp. 1039-1061.

Tversky, A. and Kahneman, D (1992), “Advances in prospect theory: cumulative representation of uncertainty”, Journal of Risk and Uncertainty, Vol. 5 No. 4, pp. 297-323.

Westerhoff, F. (2008), “The use of agent-based financial market models to test the effectiveness of regularity policies”, Jahrbucher Fur Nationalokonomie and Statistik, Vol. 228, pp. 1-57.

Westerhoff, F. and Dieci, R. (2006), “The effectiveness of Keynes–Tobin transaction taxes when heterogeneous agents can trade in different markets: a behavioral finance approach”, Journal of Economic Dynamics and Control, Vol. 30, pp. 293-322.

Wilensky, U. (1999), NetLogo, available at: http://ccl.northwestern.edu/netlogo (accessed June 8 2012).

Corresponding author

Heba M. Ezzat can be contacted at: h.m.ezzat@gmail.com

Related articles