MBA Analytics For Finance 13

Download as pdf or txt
Download as pdf or txt
You are on page 1of 10

UNIT

13 Algorithmic Trading

Names of Sub-Units

Introduction to Algorithmic Trading: Algorithmic Trading in Practice, Benefits of Algorithmic Trading,


and Application of Deep Learning in Stock Market Prediction

Overview
This unit begins with the introduction to algorithmic trading. Further, it discusses the algorithmic
trading in practice, benefits of algorithmic trading, and application of deep learning in stock market
prediction.

Learning Objectives

In this unit, you will learn to:


 Define algorithmic trading
 Discuss the algorithmic trading in practice
 Understand the benefits of algorithmic trading
 Analyse the application of deep learning in stock market prediction
 Explain the evaluation of steps included in the application of deep learning in stock market
prediction
JGI JAIN
DEEMED-TO-BE UNI VE RSI TY
Financial Analytics

Learning Outcomes

At the end of this unit, you would:


 Understand the concept of algorithmic trading
 Explain the algorithmic trading in practice
 Discuss the benefits of algorithmic trading
 Evaluate the application of deep learning in stock market prediction
 Appraise the evaluation of steps included in the application of deep learning in stock market
prediction

Pre-Unit Preparatory Material

 https://ecapitaladvisors.com/blog/what-is-financial-analytics/
 https://www.gartner.com/en/finance/glossary/finance-analytics

13.1 INTRODUCTION
Now days, almost every layman is aware about the concept of shares and securities trading in the stock
market. The stock market refers to a collection of exchanges and other venues where shares of publicly
traded firms can be bought, sold, and issued. These types of financial transactions take place on either
formal exchanges (physical or electronic) or regulated over-the-counter (OTC) marketplaces.

The stock market brings together, interacts with, and transacts with a large number of buyers and
sellers of securities. Stock markets allow for the price discovery of corporate shares and serve as a
barometer for the economy as a whole.

A stock market includes an environment that is controlled and regulated. The stock market maintains
fair pricing practices and transaction transparency by bringing together hundreds of thousands of
market participants who want to purchase and sell shares. Unlike earlier stock markets, which used
paper-based physical share certificates to issue and trade, today’s computerised stock exchanges
function entirely electronically.

This unit will highlight on the advanced techniques in the stock markets and the new methods of stock
trading. Nowadays, the traditional methods of stock trading are rarely used by the traders and investors.
On the other hand, the traders are adopting new techniques and strategies to boost up the volume of
trading in the stock market. The concept of algorithmic trading is such a new concept which facilitates
the stock trading on the basis of pre-set rules with the help of computer programming techniques.

13.2 INTRODUCTION TO ALGORITHMIC TRADING


Algorithmic trading is the technique of executing orders using automated and pre-programmed trading
instructions to account for factors such as price, time, and volume. A set of instructions for solving a

2
UNIT 13: Algorithmic Trading JGI JAIN
DEEMED-TO-BE UNI VE RSI TY

problem is known as an algorithm. Over time, computer algorithms send little chunks of the entire
order to the market.

Algorithmic trading (also known as automated trading, black-box trading or algo-trading) is when a
computer programme follows a set of instructions to execute a transaction (an algorithm). In theory,
the deal can create profits at a pace and frequency that would be hard for a human trader to achieve.

Timing, price, quantity, or any mathematical model is used to define the sets of instructions. Apart from
providing profit opportunities for traders, algo-trading makes markets more liquid and trading more
methodical by removing the influence of human emotions on trading.

Algorithmic trading makes choices to buy or sell financial securities on an exchange using complex
calculations, mathematical models, and human oversight. High-frequency trading technology, which
allows a company to make tens of thousands of deals per second, is frequently used by algorithmic
traders. Order execution, arbitrage, and trend trading methods are all examples of scenarios where
algorithmic trading can be applied.

The concept of algorithmic trading is elaborated in the figure 1 below:

Assesses Market
Situation
Develop Dynamically
Programmer Code

Saves Time For


Trader

Figure 1: Algorithmic Trading

Algorithmic Trading in Practice

Assume a trader follows the following simple trading criteria:


 Buy 50 shares of a company when its 50-day moving average crosses over its 200-day moving
average. (By taking an average of past data points, a moving average smooth’s out day-to-day price
fluctuation and so detects patterns.)
 It’s time to sell when the stock’s 50-day moving average goes below the 200-day moving average.

A computer programme will automatically watch the stock price (and the moving average indicators)
and make buy and sell orders when the preset circumstances are met using these two simple commands.
The trader no longer has to input orders manually or examine current prices and graphs. The algorithmic
trading system properly detects the trade opportunity and does this automatically.

Benefits of Algorithmic Trading


 To perform transactions, the best possible price is employed.
 Trade orders are placed quickly and precisely (there is a high chance of execution at the desired
levels).

3
JGI JAIN
DEEMED-TO-BE UNI VE RSI TY
Financial Analytics

 Trades are scheduled precisely and swiftly to minimise large price movements.
 Transaction costs are lower.
 Automated checks on multiple market conditions at the same time.
 When placing transactions, there’s a lower chance of making a mistake.
 To see if algo-trading is a feasible trading method, it can be back tested using historical and real-
time data.
 Reduces the risk of human traders making mistakes due to emotional and psychological variables.

Many types of trading and financial operations use algo-trading, including:


1. Algo-trading is used by mid- to long-term investors or buy-side corporations, such as pension funds,
mutual funds, and insurance companies that do not want to alter stock prices with discrete, large-
volume transactions.
2. Automated trade execution benefits short-term traders and sell-side participants—market makers
(such as brokerage houses), speculators, and arbitrageurs; in addition, algo-trading aids in creating
sufficient liquidity for market sellers.
3. Trend followers, hedge funds, and pair’s traders (a market-neutral trading strategy that matches
a long position with a short position in a pair of highly correlated instruments such as two stocks,
exchange-traded funds (ETFs), or currencies) find that programming their trading rules and letting
the programme trade automatically is much more efficient.

13.3 APPLICATION OF DEEP LEARNING IN STOCk MARkET PREDICTION


Prediction and analysis of the stock market are some of the most difficult tasks to execute. A classic
challenge at the confluence of finance and computer science is stock market prediction. There are
a multitude of reasons for this, including market volatility and a variety of other dependent and
independent variables that influence the market value of a particular stock. Because of these factors, it is
extremely difficult for any stock market expert to predict the market’s rise and fall with great accuracy.

However, with the advent of machine learning and its powerful algorithms, contemporary market
research and stock market prediction improvements have begun to incorporate such methodologies in
assessing stock market data. Some researchers are attempting to quantify the differences in efficiency
levels between mature and emerging markets, while others are attempting to develop effective stock
market prediction models.

The story of fundamental analysis and technical analysis is the starting point for the endeavour.
Fundamental analysis considers the stock price in terms of its inherent worth or fair value, whereas
technical analysis just considers charts and patterns.

The experience-based technical indicators can also be used as handmade input features for machine
learning and deep learning models. Following that, linear models for stock market prediction are
introduced, including the autoregressive integrated moving average (ARIMA) and generalised
autoregressive conditional heteroskedasticity (GARCH). Machine learning techniques, such as logistic
regression and support vector machine, are now being used to predict stock market movements.

4
UNIT 13: Algorithmic Trading JGI JAIN
DEEMED-TO-BE UNI VE RSI TY

The prediction issues can be categorised into four types based on the intended output and frequency: i)
daily classification, ii) daily regression, iii) intraday classification, and iv) intraday regression.

In the process of actual stock prediction, four steps of evaluation are included. They are as follows:
a. Raw data
b. Data processing
c. Prediction model
d. Model evaluation

Let us discuss each step separately to reveal a general approach of the procedure:
a. Raw Data: The first step in predicting is to gather accurate data to use as a foundation. It could be
intrinsic historical prices, assuming that history repeats itself, or extrinsic data sources influencing
the stock market. Asset prices, according to the efficient-market concept, already represent all
relevant information. In practice, however, many scholars disagree with this finding, therefore a
variety of extrinsic data sources are employed to predict stock market movements.
The training of a complicated neural network model requires a large amount of input data for
deep learning models. Different types of raw data have different levels of complexity in getting
and processing them, and different data types are used in different ways. The raw data frequently
utilised for stock market prediction is divided into seven groups for this purpose:
1. Market data
2. Text data
3. Macroeconomics data
4. Knowledge graph data
5. Image data
6. Fundamental data
7. Analytics data
b. Data Processing:
i. Missing data imputation: Because market data is more dependable and highly supported and
maintained by trading exchanges, the problem of missing data is not as severe as it is in other
sectors, such as sensor data.
ii. Denoising: The market data is packed with noise as a result of many irrational behaviours in
the stock trading process, which may misrepresent the direction of price change and mislead
forecast.
iii. Feature extraction: Feature engineering is the process of collecting input features from raw
data using domain expertise for machine learning models. These handcrafted characteristics,
when combined with raw data, are utilised as input for prediction models and can significantly
improve machine learning model performance.
iv. Dimensionality reduction: Many elements, such as technical indicators, which are all estimated

5
JGI JAINDEEMED-TO-BE UNI VE RSI TY
Financial Analytics

from historical open/high/low/close prices and volume, may be highly connected with one
another. Dimensionality reduction for the input features has been utilised as a preprocessing
strategy for stock market prediction to mitigate the relevant problem of deep learning model
overfitting.
v. Feature normalisation and standardisation: Feature normalisation and standardisation are
used to ensure that some machine learning models can work and to improve the model’s training
speed and performance when given multiple input features with varying scales. The process of
rescaling the input feature by the minimum and range to make all of the values sit between 0
and 1 is known as feature normalisation.
vi. Data split: In machine learning and deep learning domains, in-sample/out-of-sample split or
train/validation/test split of data samples is often used for evaluating alternative prediction
models.
vii. Data augmentation: For picture classification and object recognition applications, data
augmentation approaches have been widely employed and have been shown to improve
classification and detection performance.
c. Prediction Model: The majority of prediction models are supervised learning models, which use
a training set for training and a test set for evaluation. When labels aren’t provided during the
feature extraction step, only a few of the researches use semi-supervised learning. We divide the
various prediction models into three categories: standard models and variants, hybrid models, and
additional models are also available. Three deep learning model families, including feedforward
neural network, convolutional neural network, and recurrent neural network, are frequently
employed in standard models. Other models include the use of generative adversarial networks,
transfer learning, and reinforcement learning. These models have only recently emerged, and they
are still in the early stages of being used to stock market forecasting.
d. Model Evaluation: In this process, the evaluation metrics are categorised into four types for the
prediction models.
i. Classification metrics: The model’s performance on movement prediction, which is modelled as
a classification problem, is measured using classification metrics.
ii. Regression metrics: The model’s success on stock/index price prediction, which is treated as a
regression problem, is measured using regression measures.
iii. Profit analysis: Profit analysis determines whether or not the predicted-based trading strategy
will provide a profit. It is usually assessed in terms of two factors: return and risk.
iv. Significance analysis: Kruskal-Wallis (Kruskal & Wallis, 1952) and Diebold Mariano (Diebold &
Mariano, 2002) tests can be performed to assess if there is a statistically significant change in
terms of predictions when comparing the deep learning models to the baselines.

Conclusion 13.4 CONCLUSION

 A stock market is a collection of exchanges and other places where publicly listed companies’ shares
may be purchased, sold, and issued.

6
UNIT 13: Algorithmic Trading JGI JAIN
DEEMED-TO-BE UNI VE RSI TY

 The stock market brings together, interacts with, and transacts with a large number of buyers and
sellers of securities.
 The concept of algorithmic trading is such a new concept which facilitates the stock trading on the
basis of pre-set rules with the help of computer programming techniques.
 Algorithmic trading is the technique of executing orders using automated and pre-programmed
trading instructions to account for factors such as price, time, and volume.
 Algorithmic trading (also known as automated trading, black-box trading, or algo-trading) is when
a computer programme follows a set of instructions to execute a transaction (an algorithm).
 Algorithmic trading makes choices to buy or sell financial securities on an exchange using complex
calculations, mathematical models, and human oversight.
 A classic challenge at the confluence of finance and computer science is stock market prediction.
 With the advent of machine learning and its powerful algorithms, contemporary market research
and stock market prediction improvements have begun to incorporate such methodologies in
assessing stock market data.
 Fundamental analysis considers the stock price in terms of its inherent worth or fair value, whereas
technical analysis just considers charts and patterns.
 The experience-based technical indicators can also be used as handmade input features for machine
learning and deep learning models.
 The prediction issues can be categorised into four types based on the intended output and frequency:
i) daily classification, ii) daily regression, iii) intraday classification, and iv) intraday regression.
 In the process of actual stock prediction, four steps of evaluation are included. They are as follows:
a. Raw data
b. Data processing
c. Prediction model
d. Model evaluation
 The raw data frequently utilised for stock market prediction is divided into seven groups for this
purpose: 1. market data, 2. Text data, 3. Macroeconomics data, 4. Knowledge graph data, 5. Image
data, 6. Fundamental data, 7. Analytics data.
 The majority of prediction models are supervised learning models, which use a training set for
training and a test set for evaluation.
 In the model evaluation process, the evaluation metrics are categorised into four types for the
prediction models. i. classification metrics, ii. Regression metrics, iii. Profit analysis, iv. Significance
analysis.

13.5 GLOSSARY

 Stock market: A stock market is a collection of exchanges and other places where publicly listed
companies’ shares may be purchased, sold, and issued.

7
JGI JAIN
DEEMED-TO-BE UNI VE RSI TY
Financial Analytics

 Algorithmic trading: It is the technique of executing orders using automated and pre-programmed
trading instructions to account for factors such as price, time, and volume.
 Fundamental analysis: It considers the stock price in terms of its inherent worth or fair value,
whereas technical analysis just considers charts and patterns.
 Technical indicators: The experience-based technical indicators can also be used as handmade
input features for machine learning and deep learning models.

13.6 CASE STUDY: ALGORITHMIC TRADING SERVICES

Case Objective
This case study highlights how a worldwide investment firm sought to compare its present agency
electronic offering to its competitors.

The Bacidore Group is an establishment engaged in providing trading related research and consulting
services in United States. A worldwide investment firm, one out of the best clients of the Bacidore Group,
approached to the consulting firm in order to seek the services related to enhance the scope of the
services to be provided through benchmarking their existing agency electronic offering against the best-
in-class algorithms which are offered by its competitors.

The Bacidore Group performed a thorough product-by-product gap study to see how their products
and functionality compared to the competition. Interviewing key stakeholders such as business leaders,
salespeople, product managers, and technologists, as well as reviewing the products’ business logic and
historical performance, were all part of the process.

They also made detailed recommendations on where the company should focus its efforts in order to get
the most bang for their (limited) buck. They were asked to go even deeper into the product areas with
the most serious flaws as a follow-up to the gap analysis they have made. In response, they provided a
thorough roadmap outlining how the firm could improve these areas by leveraging existing technologies.

In a nutshell, the Bacidore Group provided consulting to the client which included the performance
analysis and strategy development, which in turn assisted the client to enhance quality of their algo-
trading and to provide the best-in-class algorithmic trading services in comparison with the competitors
in the prevailing markets.

Questions
1. What was the client company looking for from the Bacidore Group in terms of consulting services?
(Hint: Assistance in regard to enhance the scope of its trading services and best-in-class algo trading
service offerings compared to the competitors.)
2. What kinds of efforts were undertaken by the Bacidore Group in order to provide the solutions to the
client company?
(Hint: The group provided performance analysis, product-by-product gap study, interviewing
the key stakeholders, reviewing the historical performance of its products as well as providing a
roadmap outlining how the company could improve itself by leveraging existing technology.)

8
UNIT 13: Algorithmic Trading JGI JAIN
DEEMED-TO-BE UNI VE RSI TY

13.7 SELF-ASSESSMENT QUESTIONS

A. Essay Type Questions


1. Explain the concept of algorithmic trading.
2. What are the benefits of algorithmic trading? What are the financial operations used by the
algo-trading?
3. What is the concept of stock market prediction?
4. What are the four types of evaluation in the process of stock market prediction?

13.8 ANSWERS AND HINTS FOR SELF-ASSESSMENT QUESTIONS

A. Hints for Essay Type Questions


1. Algorithmic trading is the technique of executing orders using automated and pre-programmed
trading instructions to account for factors such as price, time, and volume. A set of instructions for
solving a problem is known as an algorithm. Algorithmic trading (also known as automated trading,
black-box trading, or algo-trading) is when a computer programme follows a set of instructions to
execute a transaction (an algorithm). Refer to Section Introduction to Algorithmic Trading

2. The benefits of algorithmic trading are:


 To perform transactions, the best possible price is employed.
 Trade orders are placed quickly and precisely (there is a high chance of execution at the desired
levels).
 Trades are scheduled precisely and swiftly to minimise large price movements.
 Transaction costs are lower.
 Automated checks on multiple market conditions at the same time.
 When placing transactions, there’s a lower chance of making a mistake.
 To see if algo-trading is a feasible trading method, it can be back tested using historical and
real-time data.

 Reduces the risk of human traders making mistakes due to emotional and psychological
variables.
Refer to sub-section Benefits of Algorithmic Trading under Section Introduction to Algorithmic
Trading
3. Prediction and analysis of the stock market are some of the most difficult tasks to execute. A classic
challenge at the confluence of finance and computer science is stock market prediction. There
are a multitude of reasons for this, including market volatility and a variety of other dependent
and independent variables that influence the market value of a particular stock. Because of these
factors, it is extremely difficult for any stock market expert to predict the market’s rise and fall with
great accuracy. Refer to Section Application of Deep Learning in Stock Market Prediction
9
JGI JAINDEEMED-TO-BE UNI VE RSI TY
Financial Analytics
4. In the process of actual stock prediction, there are four steps of evaluation included. They are as
follows:
a. Raw data
b. Data processing
c. Prediction model
d. Model evaluation
Refer to Section Application of Deep Learning in Stock Market Prediction

@ 13.9 POST-UNIT READING MATERIAL

 https://www.techtarget.com/searcherp/definition/financial-analytics
 https://www.careerizma.com/careers/financial-analyst/

13.10 TOPICS FOR DISCUSSION FORUMS

 Make a group of three/four friends to discuss about the concept of algorithmic trading.

10

You might also like