Options Tool

Charalampos G. Papadakis

September 2011

Dissertation submitted in partial fulfilment for the degree of
Master of Science in Computing For Financial Markets

Computing Science and Mathematics
University of Stirling


Abstract

Option is a financial instrument of the derivative market. In particular, it is an agreement between buyers and sellers for a transaction on an asset (e.g. stock) in a specific future day and at a specific pre-agreed price for a non-returnable premium. The main difference with other derivatives is that the buyer of the Option has the right (option) and not the obligation to exercise the derivative, to buy or sell the underlying asset, while the seller has to follow the buyer’s choice. Financial traders are very interested in them for various purposes, including hedging risk and speculating. There are plenty of models and strategies focused on Options. So, it is essential for traders to have a software package that can do automatically the mathematical calculations and display graphics that can help them to take their financial decisions.

The Options Tool focuses on the three main parts of Options trading: Options pricing, Options strategies and put call parity theorem. The program uses up-to-date equity Options data from the web page of the Financial Times (www.ft.com), giving the opportunity to the user to choose among various Options. The aim of this project is to combine the most fundamental parts of options trading in a friendly environment for the trader.

The Options Tool is a JAVA-based application. The user has to run the application, to choose his inputs and, as a result of simple button clicks, outputs are displayed, according to the choices made. The outputs could be calculations, graphs or tables. The program is separated in three main parts, each one having a different aim, so that the user can go in depth for each Option he is interested in.

My achievement is quite near the expectations. The program calculates correctly essential Options models in a friendly and easy to use environment. It can price Options using different models, calculate the Greeks, detect arbitrage and use different strategies for various purposes. Also, the graphics are displayed successfully.

.

Attestation

I understand the nature of plagiarism, and I am aware of the University’s policy on this.

I certify that this dissertation reports original work by me during my University project except for the following:

· The code (Java classes 5.1.10 – 5.1.17) discussed in Section 6.2 about Option Strategies was initially created by Mandhurananda Pahar, in his dissertation for the degree of MSc in Computing for Financial Markets in University of Stirling called ‘Implementation of VaR and Option Strategies’ (2010).

· The mathematical functions displayed in Chapter 4 and the descriptions of Options Strategies in Section 4.3 were taken from the book Options, Futures and Other Derivates by John C. Hull.

Signature Date

Acknowledgements

First of all, I would like to thank my supervisor, Dr Mario Kolberg for helping me to complete this project, giving me right directions and organizing my time.

Also, I want to give many thanks to Mandhurananda Pahar, a PhD student in the University of Stirling, who offered me his code for Option Strategies. It was a brilliant work of him, and a great point for me to start my project.

I want to acknowledge SAAS, the Student Awards Agency of Scotland [1], for giving me a scholarship, big enough to cover my tuition fees.

Last but not least, I want to thank my parents for giving me the opportunity to study abroad and having this wonderful experience in Stirling.

Table of Contents

Abstract i

Attestation ii

Acknowledgements iii

Table of Contents iv

List of Figures vii

1 Introduction 1

1.1 Background and Context 1

1.1.1 General Information for Options 2

1.1.2 Option Pricing Models 2

1.1.3 The Greeks 2

1.1.4 Options Strategies 2

1.1.5 Put Call Parity Theorem 2

1.2 Scope and Objectives 3

1.3 Achievements 4

1.4 Overview of Dissertation 4

2 State-of-The-Art 6

2.1 Pre-existing software packages 6

2.1.1 Options-Vue 6 6

2.1.2 V-Options 6

2.1.3 Option-Aid 7

2.1.4 Implementation of VaR and Option Strategies 7

2.1.5 O-Trader 7

3 System Requirments 11

3.1 Software/Technologies 11

3.1.1 Java 11

3.1.2 Java IDE 11

3.1.3 The R Project for Statistical Computing 11

3.1.4 PDFOne 11

4 Technical Analysis 12

4.1 Pricing Models 12

4.1.1 Black-Sholes-Merton Pricing Model 12

4.1.2 Binomial Pricing Model 13

4.2 Greeks 14

4.3 Options Strategies 15

4.4 Put Call Parity 16

5 Design 17

5.1 Internal Program Structure 17

5.1.1 OptionsTool.class 18

5.1.2 PricingModel.class 18

5.1.3 BinomialModel.class 19

5.1.4 BSM.class 19

5.1.5 Greeks.class 19

5.1.6 Calendar.class 19

5.1.7 Read_PDF_From_URL.class 19

5.1.8 PutCallParity.class 19

5.1.9 DetailsDialog.class 20

5.1.10 OptionStrategy.class 20

5.1.11 DataRead.class 20

5.1.12 OptionPanel.class 20

5.1.13 OptionDialog.class 20

5.1.14 XYSeriesDemo.class 20

5.1.15 OptionTableDialog.class 20

5.1.16 DataTable.class 20

5.1.17 RoundDecimalPlaces.class 21

5.2 Data Structure 21

6 Implementation 24

6.1 Pricing Models/Greeks 24

6.2 Options Strategies 29

6.3 Put Call Parity 32

7 Evaluation 34

7.1 Testing 34

7.1.1 Black-Sholes-Merton Pricing Model 34

7.1.2 Binomial Tree Pricing Model 34

7.1.3 Delta 34

7.1.4 Rho 35

7.1.5 Gamma 35

7.1.6 Vega 35

7.1.7 Theta 36

7.1.8 Put Call Parity 37

7.1.9 Possible Crash Problems 38

7.2 Feedback 38

8 Conclusion 40

8.1 Summary 40

8.2 Evaluation 40

8.3 Future Work 41

References 43

Appendix 1 – User guide 45

Appendix 2 – Installation guide 46

List of Figures

Figure 1 Options Aid Fair Value/Greeks [14] 8

Figure 2 Options Vue 6 Graphic Analysis [15] 8

Figure 3 VOptions 3D Graph [16] 9

Figure 4 OTrader Options Pricing/Greeks Calculator [17] 9

Figure 5 Options Strategies by Mandhurananda Pahar (University of Stirling) [18] 10

Figure 6 Main Program Structure 17

Figure 7 Pricing Models Structure 17

Figure 8 Option Strategies Structure 18

Figure 9 Put Call Parity Structure 18

Figure 10 BlueJ Options Tool Class Structure 21

Figure 11 www.ft.com Data Market 22

Figure 12 Data Structure 23

Figure 13 Options Tool Pricing Models 25

Figure 14 Options Tool Binomial Tree 26

Figure 15 Options Tool Calendar 27

Figure 16 Options Tool Strategies 29

Figure 17 Options Tool Strategy Graph 30

Figure 18 Options Tool Strategies Table 31

Figure 19Options Tool Intrinsic and Time Value 31

Figure 20 Options Tool Put Call Parity Panel 32

Figure 21 Options Tool Arbitrage Details 33

Figure 22 Options Tool Information 33

- i -


1 Introduction

The Options Tool is a Java-based application that focuses on financial Option trading. In this chapter there are briefly discussed the general information for Options and their models, strategies and theorems.

1.1 Background and Context

Options are widely used in financial markets, especially by traders. Their history started in the late 17th century by a small group of traders.

1.1.1 General Information for Options

Options are securities traded on the financial markets. They are part of securities called derivates. That’s because they derive their value from the underlying asset they are based on. The underlying asset could be a financial instrument like stock, currency, commodity, index or other security like Future. Options include a specific price at which the underlying asset can be bought or sold in the future and a specific time that it has to be exercised. This price is called strike price, while the expiry time is called time to maturity. The buyer has to pay a non-returnable premium to own the Option. Usually, there is a clearing house between the buyer and the seller to limit the default risk.

There are many different kinds of Options. Initially, the main difference is between Call and Put Options. Holding a Call Option gives the right to the holder to buy the underlying asset. On the other hand, holding a Put Option gives the right to the holder to sell the asset. The holder is called the part that buys the Option, while the writer is the part that sells the Option.

Another fundamental separation of Options is between European and American Options. There is no geographical significance. The main difference is that American Options can be exercised at any time until the maturity time, while European Options can be exercised only at the maturity time.

Options are extremely versatile. Traders use them for various purposes. These purposes could be either for hedging risk or speculating. Options can be used to hedge the total risk of their underlying asset. Using various strategy forms, the trader can achieve a smaller loss, in case he has to confront the worst scenario.

Speculating with options is a kind of betting. Speculator decide on future prices levels, judging from past prices fluctuations and other related available information. Betting on a specific movement of the price can lead to profit. For example, if a financial player has the feeling that a specific stock price will go higher, he can buy call options of that stock with the lower strike price, so as to speculate from the price changes. If the expectation comes true, the holder can buy an asset at a lower price than the current and then sell it at the current price. Unfortunately for the speculators, options are very risky, when they are traded alone, and as a result, they are usually traded with their underlying asset.

1.1.2 Option Pricing Models

There are plenty of models trying to evaluate the price of Options. Among them, the two most known and used are the Binomial Model and the Black-Sholes-Merton Model (BSM).

The Binomial Model was first presented by Cox, Ross and Rubinstein in 1979. It is computational slower than the BSM, but it gives more accurate results [2]. Except that, the main comparative advantage of the Binomial Model is that it can be used to price American Options, while BSM is only for European Options. That’s because it can price the Options in different time steps. As a result, American Options, which can be exercised before their expiry time, can be priced only with the Binomial Model.

The Black-Sholes-Merton Model (BSM) was introduced in 1973 by F. Black and M. Sholes and then extended in the same year by R. Merton. According to that model the prices change continuously, rather than discretely, as it is assumed in the Binomial Model.

1.1.3 The Greeks

These are the sensitivity factors of the Options and are called Greeks because they are represented with Greek letters:

Delta (δ): option’s sensitivity to stock value.

Theta (θ): option’s sensitivity to time to maturity.

Gamma (γ): option’s delta sensitivity to stock value.

Vega (ν): option’s sensitivity to volatility.

Rho (ρ): option’s sensitivity to interest rate.

They are indexes that represent the size of change in Options prices for every small change of the factors it is depended on.

1.1.4 Options Strategies

There are various strategies either for hedging risk or speculating. These strategies are combinations of Option and Stock trades. For example, it is possible to buy a stock and sell a call or buy both call and put of the same underlying stock. The profit or loss from each strategy depends on how the stock’s price will move in the future.

1.1.5 Put Call Parity Theorem

The Put Call Parity Theorem is based on the law of one price [3].This law assumes that all sellers will massively search for the higher price to sell their asset, while all buyers will flock for the lowest price. It shows the relationship between the call and the put Option of a specific asset, with same strike price and expiry date. The relationship is the following:

According to the theorem, if the equation does not hold, there are arbitrage opportunities. The arbitrageur can sell the overpriced assets and buy the underpriced ones. The Put Call Parity Theorem is used only for European Options.

1.2 Scope and Objectives

The aim of the Options Tool is the creation of a complete tool for traders focused on Option securities. My aim was to add the main Option instruments that a trader could use in one program. This combination can lead to a really useful tool for the user, with no need to switch among different programs.

It is important to highlight that the user must be a financial person. The program is focused on them, as they are specialists in trading. As a result, this program may be unfriendly to people from other backgrounds not giving so detailed information about each usage. Moreover, the program tries to be friendly to people with small experience in Finance, so as not to be ideal only for experts.

In addition, the user can be a student of Finance. This software may have an educational purpose as well. The models, the functions and the theorems that are being used are similar with those taught in the University. So, students have the opportunity to calculate functions that otherwise they have to spend significant time to figure out. Also, it can be used as for verification purposes.

The data will be taken from the Financial Times website. The Financial Times give every working day the data in a PDF format, separately for each day. The program is able to update the data, according to the user’s choice. Moreover, the application has separate parts, friendly for the user to switch among. The calculations should be accurate, because a small mistake in prices, could lead to big loss, making the software useless.

There are similar programs already for Options, but they are not free at this level. The amount of money that someone has to pay for using them is significant. Many of them belong to big organizations and banks, something that makes them difficult to approach for the average user. On the web, there are some free programs, but they just price Options with no connection to any data, so the user has to fill all the inputs manually, in a poor design.

1.3 Achievements

The Options Tool combines the essential models of Option derivatives. As a result this program is separated in three main parts:

· Pricing Options

· Options Strategies

· Put Call Parity Theorem

Each part focuses on different applications for the selected Option. So, the user can select a specific Option and switch among the three panels, in order to take the available outputs.

The first panel, called Pricing Options, gives information about the prices of Options. It also calculates sensitivity factors, ‘the Greeks’, for the selected Option.

In the second panel the trader can choose among the most important Option Strategies and take back tables and graphics for the selected strategy.

In the third panel arbitrage opportunities are detected. The program checks if there are mispriced assets and gives details about how the user has to act to receive the profit.

There is financial information, in each part, helping the user to understand the process. Once again, the program is focused on financial people and as a result the given information is not so detailed, something that may make the program hard to use from people outside the financial sector. But, this was not in the purposes of this project. Except for the financial information, there is also guidance in the way the user has to choose the inputs, so as to avoid incompatible inputs.