Artificial intelligence applied to investment in variable income through the MACD (moving average convergence/divergence) indicator.

AutorAguirre, Alberto Antonio Agudelo

The authors would like to thank Marlon Aguirre Sanchez (Universidad Nacional de Colombia, Business Administration Faculty) for his valuable contribution to the study by programing genetic algorithms.

Originality/value--This paper looks at machine learning as an up-to-date tool with great potential for increasing effectiveness in profits when applied into TA investment approaches using MACD in well-developed stock markets.

Keywords Artificial intelligence, Genetic algorithms, Investment, MACD, Stock market, Technical analysis, Variable income

Paper type Research paper

Nomenclature ANN artificial neural networks BB Bollinger bands B&H buy and hold DAX Deutscher Aktien index DJI Dow Jones industrial ETF exchange traded fund GA genetic algorithms GE grammatical evolution GP genetic programming MACD moving average convergence/divergence MLP multi-layer perceptron NASDAQ national association of securities dealers automated quotations RSI relative strength index S&P 500 standard and poor's 500 TA technical analysis TSE 300 Toronto stock exchange 300 Italic letters EMA exponential moving average N number of data SMA simple moving average Greek symbols [[theta].sub.1],[[theta].sub.2] number of data for the slower moving average and faster moving average, respectively [L.sub.B],[L.sub.S] buy limit and sell limit orders, respectively 1. Introduction

Stock markets attract the attention of economists, financiers and rulers around the world due to the benefits that their activity provides to the real economy because they serve as an instrument for mobilizing savings toward investment and as a mechanism for allocating resources in the economy (Gupta-Bhattacharya et al., 2014).

Within the stock market, investment in equity assets stands out for the possibility of achieving a return higher than most investments in the market while companies are allowed to resort to financing sources with lower cost (Ibrahim, 2011). Equity assets are characterized by a high level of volatility in their returns which makes them difficult to forecast. This is how numerous studies have concluded that the prediction of prices for this type of asset is a very difficult task to achieve due to the characteristics of nonlinearity and non-stationarity of prices (Farias et al., 2017). This means that historical volatility does not have a constant relationship with the so-called implied volatility that tries to determine the variability of the price of the asset in the future (Narwal et al., 2018).

There are two general strategies for equity assets investment analysis: fundamental analysis and traditional technical analysis (henceforth referred to as TA). These strategies have very different approaches and are generally considered independently. However, despite their differences, they have the common purpose of trying to predict prices and returns on assets. Fundamental analysis focuses on the study of the intrinsic value of the assets based on the establishment of the value of the underlying companies, for which it considers the study of all the elements of the economy, the industry and the company in particular (Kumar et al., 2013). The profitability of this strategy is achieved by holding the portfolio and the liquidation of assets when they reach the expected valuation level, which occurs when the market price approaches its intrinsic value. On the other hand, TA uses historical data of the prices and the volumes traded to find signs that indicate the possible future behavior of the price to obtain returns through the holdingofassets forshort periodsoftime (usually assets characterizedbya high level of volatility) to take advantage of sudden rises or falls in the price (Murphy, 1999).

On the other hand, TA directs its interest in trying to identify patterns in historical prices that allow predicting possible behaviors in the short term under the premise that, any aspect that may have an impact on the price either of the company, the market, the economy, or the political situations or psychological aspects of investors, has already been incorporated into it. The categories TA is divided into are graphical analysis and analysis through indicators, which are used by investors individually or jointly to make decisions about the position to be assumed with an asset at a given time. Graphical analysis is oriented toward the study of the figures that trace historical price data and, therefore, the effort of the analysts is focused on finding and interpreting those forms to determine patterns that show the expected behavior in the immediate future (Anggono and Herlanto, 2019).

For many studious scholars in financial markets, TA has evolved in recent years moving from graphic analysis with predominance on visual interpretation and high subjectivity load, to the use of sophisticated statistical and computational tools (Metghalchi and Garza, 2013). These advanced analysis tools include moving averages, the relative strength index (RSI), Bollinger bands (BB), the moving average convergence/divergence (MACD), the stochastic process and momentum indicators, as well as another important number of indicators (Gold, 2015) which help to analyze the momentum of the price trend to identify weaknesses that indicate a possible change in the trend into the future. Among the different indicators of TA, one of the most used by traders worldwide is the MACD (Agudelo Aguirre et al., 2020). MACD is constructed by three lines: one is the so-called MACD line, which is calculated as a difference of two exponential moving averages (EMAs) of the price of the asset with a standard data number of 26 and 12, a second line that conforms to the EMA of nine MACD line data and a third fixed horizontal line with the value of zero (Ivanovski et al., 2017). Although these parameters are used in general for the construction of the indicator to be applied in different typesofinvestment, there are studies suchas the one carried outby Wang and Kim (2018) that determine that the validity and sensitivity of the MACD have a strong relationship with the selection of the parameters which could produce a higher or a lower return, depending on the behavior of the asset pricing.

In recent years, in addition to the traditional TA (referred hereto as the analysis performed under typical parameter values, as discussed later in this study, and under non-automatization or any other computerized mean), some parallel approaches have taken importance in the financial analysis of investments in the stock market. This is how computational tools have been applied to the TA using indicators to achieve greater efficiency and objectivity in the analysis. Among the most notable computational tools used for analysis are genetic algorithms (GA) (Holland, 1975), neural networks, diffuse logic and Markov. The need to resort to computational models is due to the nonlinearity and complexity of the financial system, which is composed of a series of interrelated subsystems and exposed to various particular and systemic risks. Therefore, in comparison to deterministic models, the application of computational models has facilitated the design and implementation of investment strategies and has allowed greater efficiency in results (Dubinskas and Urbsiene, 2017).

The line of research followed in this study was focused on the application of GA into a technical setup for improved returns from investment (compared to other traditional analyses namely TA and B&H). GA belongs to, along with evolutionary programming, evolutionary strategies and genetic programming (GP), the four historical paradigms of evolutionary computation (Abdel-Basset et al, 2018). All these methods are classified as metaphor-based metaheuristics, that is, algorithms that simulate natural phenomena such as biological evolution, human behavior, etc. (Abdel-Basset et al, 2018). Into the context of artificial intelligence, heuristic refers to those aspects dealing with the use of knowledge for portraying the dynamic performance of tasks. In other words, it is said heuristic to refer to an intelligent method for doing a task, which is not resulting from rigorous and exhaustive analysis, but from the expertise about that specific task (Sorensen, 2015).

GA mimics the natural evolution by an efficient exploration of the search space under presumptions of survival of the fittest to find increasingly fitter and better-adapted individuals (Jacobsen and Kanber, 2016). During this process, the most fitting individuals to renovate the population are crossed and those least fitted are then eliminated. At the end of the process, the solution to the optimization problem is found to be the most apt (fittest) chromosome (Metaxiotis and Psarras, 2004). GA is particularly helpful to solve problems when they are constantly changing, and requiring an adaptive solution, as occurs for prices in stock markets. When looking at stock prices, accurate predictions can be a challenging task as a result of its high...

Para continuar leyendo

Solicita tu prueba

VLEX utiliza cookies de inicio de sesión para aportarte una mejor experiencia de navegación. Si haces click en 'Aceptar' o continúas navegando por esta web consideramos que aceptas nuestra política de cookies. ACEPTAR