Use of mathematical methods for development of trading strategy
Заказать уникальную курсовую работу- 18 18 страниц
- 7 + 7 источников
- Добавлена 28.07.2021
- Содержание
- Часть работы
- Список литературы
- Вопросы/Ответы
Introduction 3
1 Theoretical foundations of mathematical methods for the development of a trading strategy 4
1.1 Using mathematics in trading 4
1.2 The concept and essence of quantitative trading 7
2 Development of a trading algorithm for a pair trading strategy 12
Conclusion 17
List of references 18
That is, there exists an a such that r = x -ax y ~ I (0). If some linear combination of two time series has an order of integration less than the order of integration of each of the series, then the time series is said to be cointegrated.The pair trading strategy allows you to make money on a short-term imbalance in profitability or asset prices with a high degree of correlation. On thea couple of similar companies from the same sector of the economy are influenced by the same external factors. Consequently, stock prices should react to such events in approximately the same way. Therefore, the short-term imbalance in the established ratio of prices should be compensated for in the direction of long-term parity. Thus, if one security has significantly increased or decreased in price relative to the other, then it is necessary to short sell the overvalued security and buy the undervalued security. With this approach, the profitability will depend not on the general direction of the market movement, but on the future ratio of the value of one valuable paper to another. At the same time, a trader cannot be 100% sure of the restoration of fair prices, he only relies on a statistical forecast about the return of the spread between two shares to their average values. Pair trading is often confused with math arbitrage, although there are major differences between the two:1) in mathematical arbitrage, they buy and sell at the same time the same underlying asset, only in different markets and / or in different forms (spot, option, futures) - in pair trading, two different underlying assets are used;2) mathematical arbitrage is possible only between instruments that are linked by an unambiguous mathematical formula.For example, the price of a futures contract is determined through three variables: the share price, the risk-free rate, and the life of the contract. Therefore, short-term changes in the price of the underlying stock should be instantly reflected in the price of the futures. At the moment of expiration, the prices of the stock and the futures must converge at one point simply by the definition of the futures. Therefore, any deviation of the futures price from the strict mathematical law will necessarily be compensated. In pair trading, the trader assumes the risk that the imbalance between assets may become trending, i.e. the correlation between the instruments will be violated.In accordance with the above, a prerequisite for successful trading on a pair trading strategy is a careful selection of assets for operations.Securities selection criteria:1) securities must be from the same sector of the economy. Two companies from the banking sector that are listed on the New York Stock Exchange (NYSE) are considered as an example: American Express (ticker - AXP) and Capital One Financial Corp. (t-ker -COF). The quotation charts for these securities are shown in Fig. 2.1;2) there must be a high degree of correlation between assets. At the same time, highly correlated instruments are those in which the average value of the correlation coefficient for 100, 180 and 360 days is above 70%. When determining pairwise correlations, it is advisable to work with increments of logarithms of prices, because the presence of a general trend in the stock market may unreasonably overestimate the degree of correlation. Table 2.1 presents the values of the correlation between AXP and COF for periods of 100, 180 and 360 days and their average value;3) the spread between the two assets should be more or less stationary. To do this, when selecting instruments, it is necessary to check for the cointegration of the spread (ratio). Ratio is the ratio of the absolute values of the prices of one security to another. However, when using absolute values of prices when constructing a spread, a quadratic trend introduces a strong distortion, so it is necessary to work with logarithms of prices or with the standard deviation of the spread (Delta). Delta shows how many standard deviations of two assets are from the average and how often the ratio "takes out". The filter when selecting securities by Delta is the frequent deviation of the ratio from the average value, but the number of standard deviations that the spread “takes out” should be more or less stable. As mentioned earlier, the spread must be stationary. Stationarity is the property of a process not to change its characteristics over time. Stationarity of a random process means the invariance in time of its probabilistic laws, while usually two types of stationarity are considered: 1) stationarity in the narrow sense, when finite-dimensional distributions are invariant with respect to the time shift; 2) stationarity in the broad sense, when only the mathematical expectation does not depend on time. In relation to pair trading, stationarity is expressed as the constancy of the mathematical expectation of the asset spread. However, it is not possible to find an ideal pair of assets, the spread of which would fully comply with the stationarity condition. Therefore, with this type of trading, it is important that either the changes in the mathematical expectation are insignificant, or it changes very smoothly, without jumps. At the same time, frequent deviations of the spread from the mathematical expectation make it possible to make frequent transactions. These deviations should be sufficient to cover commission and slippage. Thus, when choosing a pair of assets for drawing up a synthetic spread, the main conditions are smooth mathematical expectation and maximum variance.Figure 2.1 - 1. Charts of AXP and COF quotesTable 2.1 - Correlation values of AXP and COFPeriodCorrelation,%For 100 days97.22%3a 180 days95.56%For 360 days58.28%Average83.69%The author checked the cointegration of the two instruments using the Dickey - Fuller test (DF test), a technique that is used in applied statistics and econometrics to analyze time series in order to check for stationarity. It is one of the unit root tests. It was proposed in 1979 by David Dickey and Wayne Fuller [4, p. 427 - 431]. Using this test, the value of the coefficient a in the first-order autoregressive equation AR (1) is checked:У = ахУt + £, whereyt is a time series; £ is an error.If a = 1, then the process has a unit root, in this case the series yt is not stationary, it is an integrated time series of the first order - 1 (1). If | a | <1, then the series is stationary - 1 (0). For financial and economic processes, the value of | a | > 1 is not typical, since in this case the process is "explosive". The emergence of such processes is unlikely, since the financial and economic environment is quite inertial, which does not allow taking infinitely large values for short periods of time. In fig. 2.2 shows a graph of the values obtained as a result of the Dickey-Fuller test over the time series of quotes for AXP and COF securities, which indicate the representativeness of the selected asset for trading with the above selection conditions.Summing up, let's highlight the main stages of work on the pair trading strategy:1) find tools that meet the above conditions;2) calculate the weighting factors, i.e. entry volumes into positions based on the spread values in order to balance the volatility of instruments in monetary terms;3) sell an overvalued security and buy an undervalued one when Delta reaches the statistically optimized value and close both positions when returning to the average values. In fig. 2.3 is an example of trading the AXP - COF pair. An arrow pointing up indicates a simultaneous purchase of AXP and a sale of COF, and an arrow pointing down indicates a simultaneous sale of AXP and a purchase of COF. A square on the chart means closing positions on two instruments at the same time, i.e. for the first deal marked in Fig. 3, at the moment Delta crosses the zero line, it is necessary to sell the previously purchased AXP security and buy the previously sold COF security.Figure 2.2 - Cointegration of AXP and COF over a period of 180 daysFigure 2.3 - Trading a pair of AXP and COFConclusionThus, the following conclusions can be drawn.In conclusion, one more feature of this type of trading should be noted: in addition to the return of the spread to the average, you can trade short-term emissions. Deviations of the spread from its "axis of rotation" occur quite smoothly and inertially, noisy with high-frequency chaotic oscillations. Therefore, spread deviations and reverse convergence can be divided into global and local (short-term) ones. That is, having begun to expand, the spread draws a fractal upward trajectory. You can wait long enough for it to get out of the confidence range, or you can trade these very high-frequency short-term fluctuations. It is the short-term divergences of a highly correlated pair, caused by emotions or inefficiency of traders, that have the greatest chances of being compensated in the opposite direction. Longer-term deviations may well be caused by as yet unknown fundamental reasons and may not have “fair” prerequisites for returning to their average values.List of referencesGorbunov V.S. Modern mechanisms of the futures and options markets of the Russian Federation // Vestnik SGSEU. 2011. No. 1 (35).Krasovsky N.V. Options as instruments of currency risk management // Vestnik SGSEU. 2012. No. 1 (40).Shweri R. Rational Choice Theory: Universal Means or Economic Imperialism? // Economic Issues. 1997. No. 7.Dickey D.A., Fuller W.A. Distribution of the Estimators for Autoregressive Time Series with a Unit Root // Journal of the American Statistical Association. 1979. No. 74.Engle R.F., Grander C.W.J. Co-integration and Error Correction: Representation, Estimation and Testing // Econometrics. 1987. Vol. 55. No. 2.Ganapathy V. Pair Trading: Quantitative Methods and Analysis. 2008.Wyser-Pratte Guy P. Risk Arbitrage. Guy Wyser-Pratte. Wiley Investment Classics, 2009.
2. Krasovsky N.V. Options as instruments of currency risk management // Vestnik SGSEU. 2012. No. 1 (40).
3. Shweri R. Rational Choice Theory: Universal Means or Economic Imperialism? // Eco-nomic Issues. 1997. No. 7.
4. Dickey D.A., Fuller W.A. Distribution of the Estimators for Autoregressive Time Se-ries with a Unit Root // Journal of the American Statistical Association. 1979. No. 74.
5. Engle R.F., Grander C.W.J. Co-integration and Error Correction: Representation, Es-timation and Testing // Econometrics. 1987. Vol. 55. No. 2.
6. Ganapathy V. Pair Trading: Quantitative Methods and Analysis. 2008.
7. Wyser-Pratte Guy P. Risk Arbitrage. Guy Wyser-Pratte. Wiley Investment Classics, 2009.
Вопрос-ответ:
Какие теоретические основы лежат в основе использования математических методов для разработки торговой стратегии?
Использование математических методов в разработке торговых стратегий имеет свои теоретические основы. Одна из них - концепция квантитативной торговли, которая предполагает использование математических моделей и статистических данных для принятия торговых решений. Еще одна основа - концепция парной торговли, основанная на анализе корреляций между двумя активами и использовании математических методов для определения моментов покупки и продажи активов.
Как использование математических методов может помочь в торговле?
Использование математических методов в торговле позволяет анализировать большие объемы данных и предсказывать тенденции на рынке. Математические модели и статистические методы позволяют выявлять закономерности и корреляции между разными факторами, что помогает принимать более обоснованные решения на рынке.
Что такое квантитативная торговля?
Квантитативная торговля - это подход к торговле, основанный на использовании математических моделей, статистических данных и алгоритмов для принятия решений на рынке. Квантитативные трейдеры используют программирование и компьютерные системы для автоматизации торговых стратегий и анализа рынка.
Как разрабатывается торговый алгоритм для стратегии парной торговли?
Разработка торгового алгоритма для стратегии парной торговли включает несколько шагов. Сначала проводится анализ корреляции между двумя активами. Затем на основе полученных данных разрабатывается математическая модель, которая позволяет определить моменты покупки и продажи активов. После этого алгоритм программируется и тестируется на исторических данных, чтобы проверить его эффективность и прибыльность.
В чем заключается суть концепции парной торговли?
Концепция парной торговли основана на идее использования корреляции между двумя активами для принятия торговых решений. Парная торговля предполагает одновременную покупку одного актива и продажу другого актива, которые имеют высокую степень корреляции между собой. Такой подход позволяет защититься от общих рыночных факторов и сосредоточиться на разнице в ценах между активами.
Каковы основы математических методов для разработки торговой стратегии?
Основы математических методов для разработки торговой стратегии включают использование математики в торговле и концепцию и сущность квантитативной торговли.
Как математика применяется в торговле?
Математика применяется в торговле для анализа и прогнозирования данных, выявления закономерностей, разработки математических моделей и алгоритмов для принятия торговых решений.
Что такое квантитативная торговля?
Квантитативная торговля - это концепция торговли, в которой принятие решений основано на математических и статистических методах, использовании автоматизированных систем и алгоритмов.
Как разрабатывается алгоритм для стратегии парной торговли?
Алгоритм для стратегии парной торговли разрабатывается путем анализа и сравнения временных рядов, определения коэффициентов корреляции, применения математических моделей для определения точек входа и выхода из позиции.
Каковы основные выводы данной работы?
Основные выводы данной работы заключаются в том, что использование математических методов для разработки торговой стратегии может повысить эффективность торговли, улучшить прогнозирование ценовых движений и снизить риски.
Какие теоретические основы лежат в основе математических методов для разработки торговой стратегии?
Теоретические основы математических методов для разработки торговой стратегии включают использование математики в торговле, понятие и сущность количественной торговли.