📖[PDF] An Introduction to Algorithmic Trading by Edward Leshik | Perlego (2024)

📖[PDF] An Introduction to Algorithmic Trading by Edward Leshik | Perlego (1)

Part I

INTRODUCTION TO TRADING ALGORITHMS

Preface to Part I

Fabrizzio hit the SNOOZE he was dreaming he hit the TRADE key and within 15 milliseconds hundreds of algorithms whirred into life to begin working his carefully prethought commands. ALARM went off again, time to get up with the haze of the dream session End of day lingering, net for the day $10 000 000 … not bad, not bad at all, he smiled as he went into his ‘getting to work routine.’

Can we trade like that? Answering this question is what this book is all about.

Algorithmic trading has taken the financial world by storm. In the US equities markets algorithmic trading is now mainstream.

It is one of the fastest paradigm shifts we have seen in our involvement with the markets over the past 30 years. In addition there are a number of side developments operated by the Tier 1 corporations which are currently the subject of much controversy and discussion – these are based, to a great extent, on ‘controversial’ practices available only to the Tier 1 players who can deploy massive resources which disadvantage the individual, resource-limited, market participant.

No doubt the regulatory machinery will find a suitable compromise in the near future and perhaps curtail some of the more flagrant breaches of ethics and fair play – an area in which Wall Street has rarely excelled and now could well do with some help to restore the dented confidence of the mass public.

Notwithstanding these side issues, the explosive growth of algorithmic trading is a fact, and here to stay.

Let us examine some of the possible reasons for such a major and dramatic shift.

We believe the main reasons for this explosive growth of algorithmic trading are: Rapid cost reduction; better controls; reduction of market impact cost; higher probability of successful trade execution; speed, anonymity and secrecy all being pushed hard by market growth; globalization and the increase in competition; and the huge strides in advancing sophisticated and available technology.

In addition there is also the conceptual and huge advantage in executing these carefully ‘prethought’ strategies at warp speed using computer automation all of which would be well beyond the physical capability of a human trader.

Algorithmic trading offers many advantages besides the ability to ‘prethink’ a strategy. The human trader is spared the real-time emotional involvement with the trade, one of the main sources of ‘burn out’ in young talented traders. So in the medium term there is a manpower saving which, however, may be offset by the requirement for a different type of employee with more expensive qualifications and training.

Algos can execute complex math in real time and take the required decisions based on the strategy defined without human intervention and send the trade for execution automatically from the computer to the Exchange. We are no longer limited by human ‘bandwidth.’ A computer can easily trade hundreds of issues simultaneously using advanced algorithms with layers of conditional rules. This capability on its own would be enough to power the growth of algorithmic trading due to cost savings alone.

As the developments in computer technology facilitated the real-time analysis of price movement combined with the introduction of various other technologies, this all culminated in algorithmic trading becoming an absolute must for survival – both for the Buy side and the Sell side and in fact any serious major trader has had to migrate to the use of automated algorithmic trading in order to stay competitive.

A Citigroup report estimates that well over 50% of all USA equity trades are currently handled algorithmically by computers with no or minimal human trader intervention (mid-2009). There is considerable disagreement in the statistics from other sources and the number of automated algorithmic trades may be considerably higher. A figure of 75% is quoted by one of the major US banks. Due to the secrecy so prevalent in this industry it is not really possible to do better than take an informed guess.

On the cost advantage of the most basic automated algorithmic trading alone (estimated roughly at 6 cents per share manual, 1 cent per share algorithmic) this is a substantial competitive advantage which the brokerages cannot afford to ignore. Exponential growth is virtually assured over the next few years.

As the markets evolve, the recruitment and training of new algo designers is needed. They have to be constantly aware of any regulatory and systemic changes that may impact their work. A fairly high level of innate intellectual skill and a natural talent for solving algorithmic area problems is a ‘must have’ requirement.

This is changing the culture of both the Buy side and Sell side companies. Many traders are replaced by ‘quants’ and there is a strong feeling on the Street of ‘physics’ envy. A rather misplaced and forlorn hope that the ability to handle 3rd order differential equations will somehow magically produce a competitive trading edge, perhaps even a glimpse of the ‘Holy Grail,’ ALPHA on a plate.

As the perception grows in academic circles that the markets are ‘multi-agent adaptive systems’ in a constant state of evolution, far from equilibrium, it is quite reasonable and no longer surprising when we observe their highly complex behavior in the raw.

‘Emergence,’ which we loosely define as a novel and surprising development of a system which cannot be predicted from its past behavior, and ‘phase transition’ which is slightly more capable of concise definition as ‘a precise set of conditions at which this emergent behavior occurs,’ are two important concepts for the trading practitioner to understand. ‘Regime’ shifts in market behavior are also unpredictable from past market behavior, at least at our present state of knowledge, but the shifts are between more or less definable states.

Financial companies and governments from across the world are expected to increase their IT spending during 2010.

Findings from a study by Forrester (January 2010) predicted that global IT investment will rise by 8.1% to reach more than $1.6 trillion this year and that spending in the US will grow by 6.6% to $568 billion.

This figure may need revising upward as the flood of infrastructure vendors’ marketing comes on stream.

As one often quoted Yale professor (Andrew Lo) remarked recently: ‘It has become an arms race.’

Part I of this book is devoted mainly to the Tier 1 companies. We shall first describe in broad outline what algorithms are, describe some of the currently popular trading algorithms, how they are used, who uses them, their advantages and disadvantages. We also take a shot at predicting the future course of algorithmic trading.

Part II of this book is devoted to the individual trader. We shall describe the Leshik-Cralle ALPHA Algorithmic trading methodology which we have developed over a period of 12 years. This will hopefully give the individual trader some ammunition to level the trading playing field. We shall also provide a basic outline of how we design algorithms, how they work and how to apply them as an individual trader to increase your ability to secure your financial future by being in direct and personal control of your own funds.

In general we have found that successful exponents of algorithmic trading work from a wide interdisciplinary knowledge-base. We shall attempt to provide some thoughts and ideas from various disciplines we have visited along the way, if only in the briefest of outlines. Hopefully this will help to provide an ‘information comfort zone’ in which the individual trader can work efficiently and provide a route for deeper study.

📖[PDF] An Introduction to Algorithmic Trading by Edward Leshik | Perlego (2)

Chapter 1

History

The origin of the word ‘Algorithm’ can be traced to circa 820 AD when Al Kwharizmi, a Persian mathematician living in what is now Uzbekistan, wrote a ‘Treatise on the Calculation with Arabic Numerals.’ This was probably the foundation stone of our mathematics. He is also credited with the roots of the word ‘algebra,’ coming from ‘al jabr’ which means ‘putting together.’

After a number of translations in the 12th century, the word ‘algorism’ morphed into our now so familiar ‘algorithm.’

The word ‘algorithm’ and the concept are fundamental to a multitude of disciplines and provide the basis for all computation and creation of computer software.

A very short list of algorithms (we will use the familiar abbreviation ‘algo’ interchangeably) in use in the many disciplines would cover several pages. We shall only describe some of those which apply to implementing trading strategies.

If you are interested in algorithms per se, we recommend Steven Skiena’s learned tome, ‘The Algorithmic Design Manual’ – but be warned, it’s not easy reading. Algos such as ‘Linear Search,’ ‘Bubble Sort,’ ‘Heap Sort,’ and ‘Binary Search’ are in the realm of the programmer and provide the backbone for software engineering (please see Bibliography).

As promised above, in this book (you may be relieved to know) we shall be solely concerned with algorithms as they apply to stock trading strategies. In Part I we deal with the Tier 1 companies (the major players) and in Part II of this book we consider how algorithmic strategies from basic to advanced may best be used, adapted, modified, created and implemented in the trading process by the individual trader.

The earliest surviving description of what we now call an ‘algorithm’ is in Euclid’s Elements (c. 300 BC).

It provides an efficient method for computing the greatest common divisor of two numbers (GCD) making it one of the oldest numerical formulas still in common use. Euclid’s algo now bears his name.

The origin of what was to become the very first algorithmic trade can be roughly traced back to the world’s first hedge fund, set up by Alfred Winslow Jones in 1949, who used a strategy of balancing long and short positions simultaneously with probably a 30:70 ratio of short to long. The first stirring of quant finance …

In equities trading there were enthusiasts from the advent of computer availability in the early 1960s who used their computers (often clandestinely ‘borrowing’ some computer time from the mainframe of their day job) to analyze price movement of stocks on a long-term basis, from weeks to months.

Peter N. Haurlan, a rocket scientist in the 1960s at the Jet Propulsion Laboratory, where he projected the trajectories of satellites, is said to be one of the first to use a computer to analyze stock data (Kirkpatrick and Dahlquist, pp. 135). Combining his technical skills he began calculating exponential moving averages in stock data and later published the ‘Trade Levels Reports.’

Computers came into mainstream use for block trading in the 1970s with the definition of a block trade being $1 million in value or more than 10 000 shares in the trade. Considerable controversy accompanied this advance.

The real start of true algorithmic trading as it is now perceived can be attributed to the invention of ‘pair trading,’ later also to be known as statistical arbitrage, or ‘statarb,’ (mainly to make it sound more ‘cool’), by Nunzio Tartaglia who brought together at Morgan Stanley circa 1980 a multidisciplinary team of scientists headed by Gerald Bamberger.

‘Pair trading’ soon became hugely profitable and almost a Wall Street cult. The original team spawned many successful individuals who pioneered the intensive use of computing power to obtain a competitive edge ...

📖[PDF] An Introduction to Algorithmic Trading by Edward Leshik | Perlego (2024)
Top Articles
Latest Posts
Article information

Author: Catherine Tremblay

Last Updated:

Views: 6453

Rating: 4.7 / 5 (47 voted)

Reviews: 94% of readers found this page helpful

Author information

Name: Catherine Tremblay

Birthday: 1999-09-23

Address: Suite 461 73643 Sherril Loaf, Dickinsonland, AZ 47941-2379

Phone: +2678139151039

Job: International Administration Supervisor

Hobby: Dowsing, Snowboarding, Rowing, Beekeeping, Calligraphy, Shooting, Air sports

Introduction: My name is Catherine Tremblay, I am a precious, perfect, tasty, enthusiastic, inexpensive, vast, kind person who loves writing and wants to share my knowledge and understanding with you.