financialnoob.me

Blog about quantitative finance

Pricing derivatives with binomial tree model (Part 1)

In this article I will describe a discrete model (binomial tree model) for pricing derivative contracts. Most of the books and online resources that I’ve found are either too technical (math-heavy) or too simplistic (just provide formulas without explaining why it actually works). It is especially true when it comes to continuous time models. One resource that explains everything at the level I wanted is this book: ‘Financial calculus: an introduction to derivative pricing’ (Baxter and Rennie). But still some parts were not explained clear enough and in some parts notation was a bit confusing. I’m going to try to give a detailed explanation of binomial tree model and how and why it works for pricing derivatives. I will I’ll try to keep it simple enough so that anyone with basic knowledge of probability theory can understand it. I assume that reader has some knowledge of financial markets and derivative contracts.


First of all we need to understand what is no-arbitrage principle and why do we need to use it to price derivatives. Assume that we have a stock S that follows some parametric distribution. Let’s assume that the price of the stock one year from now follows normal distribution with mu=100 and sigma=10. Price of the stock today is S_0=80. We also assume that we can invest and borrow money at a risk-free rate r_f.

Problem setup

We want to price a 1-year forward contract for this stock. It means that we enter into agreement today to buy (or sell) one unit of stock one year from now for a price F. The price F must be determined today, but the actual exchange happens one year later. How should we calculate this price?

According to the definitions above we know that the expected value of the stock price one year from now is 100. Should we use this expected value to price the contract? Let’s see what happens if we do.

If we are able to enter into a contract today to sell one unit of stock for 100one year from now, then we can just borrow 80 today at 5% risk-free rate, buy one stock today, wait one year, sell the stock for 100, return the loan 80*1.05=84 and make a risk-free profit of 100–84=16. If such contracts existed it’ll be an opportunity to make free money from nothing. Such opportunities are called arbitrage opportunities.

The idea of no-arbitrage pricing is that the price of derivative contract must be such that there are no (opportunities to make risk-free profit). In case of the forward contract it is:

Forward contract pricing formulas

Let’s assume that r_f is continuously compounded return. The price of the forward contract is then:

Forward contract price

The claim is that this is the only price that doesn’t allow arbitrage. Let’s check it. If the price of the forward is larger than the one calculated above then the forward is overpriced and there is an arbitrage opportunity. To exploit this opportunity we should sell a forward contract, borrow S_0 to buy a stock and hold it for one year. Then after one year we have a profit of:

Arbitrage profit (overpriced forward)

After repaying a loan one year later we are left with a positive amount of money making a risk-free profit.

If the price of the forward is lower, then we do the opposite: buy a forward, short sell the stock and invest the money we got at a risk-free rate. In the end of one year we get:

Arbitrage profit (underpriced forward)

We see that there is only one possible price for a forward contract that does not allow arbitrage and it depends only on stock price today, risk-free rate and time to maturity. We don’t care at all what the price of the stock could be in one year. This price is enforced. If the price was different, anyone can construct a portfolio to get a risk-free (arbitrage) profit.

How about pricing other (more complicated) derivative contracts? To do this we need to have some market model. Consider binomial tree model. Let’s say we have only one period and only two possible states of the world in the end of that period. The probability of being in each state of the world is known. There are two instruments in our market: stock and cash (bond). Bond gives return r in the end of the period regardless of the state of the world. The price of the stock is different in each of the states. Below you can see a diagram representing our model.

Binomial model (1 period)

The stock will be worth s_u with probability p and s_d with probability (1–p).

We want to price a derivative on stock S. Generally speaking the payout of a derivative can be any function f(S). Knowing probability p we can calculate expected value of the stock price at time t=1 (at the end of the period), but as we’ve seen above using expected value doesn’t lead to an arbitrage-free price. We want to price such derivative by replicating its payoff using two available instruments — stock and bond.

For simplicity I will call state where S=s_u an up state, and state where S=s_da down state. We need to replicate a payoff of f(s_u) in up state and f(s_d) in down state. Assume that at time t=0 we invest in portfolio of phi stocks and psi bonds (I assume that bond is worth one dollar, so we just have psi dollars invested in bonds). Then we can try solving the following equations:

Value of portfolio at t=1

I assume above that the length of time period is one year and continuously compounded risk-free rate is r.

If we can solve both equations together then we can replicate the payout of a given derivative and therefore determine its arbitrage-free price (which is equal to the price of constructing a portfolio). The solution to the system of equations above is:

Solution

Then the price of the replication portfolio (and of the derivative contract) is:

Price of replicating portfolio (and of derivative)

Note that it does not depend at all on probabilities of being in up or down state.

Let’s implement and test this model in python. We can easily implement a function to calculate the value V of a derivative contract. To do this we need to know current stock price (s_0), stock price in the up state (s_u), stock price in down state (s_d), payout of derivative in up state (f_u), payout of derivative in down state (f_d) and risk-free rate (r). Code for that function is provided below. Remember that we are still working with a very simple 1-period binomial model.

Let’s look at a couple of examples. On the screenshot below you can see how I define parameters of the model and calculate the price of a call option with strike price K=90. The price of an option is approximately 5.73, which is equal to the price of replicating portfolio consisting of phi=0.25 units of stock and psi=-14.27 units of cash. Then we calculate the price of replicating portfolio in up/down states and see that it matches the payout of a call option with strike price K=90 (10 in up state, 0 in down state).

Pricing call option

Repeating the same with a put option (with the same model parameters and strike price) we get a price of 11.34. The replicating portfolio consists of phi=-0.75 units of stock and psi=71.34 units of cash. Price of the replicating portfolio in up/down states matches the payout of the option (0 in up state, 30 in down state)

Pricing put option

Now we can easily extend the binomial model to contain more periods. The calculation will be exactly the same, we will just break multiple period problem into several one-period problems. Assume we have two periods as on the diagram below.

Binomial model (2 periods)

We start at the end and work backwards. Assume we want to price a call option with strike price K=90 and we have the stock price model shown below.

Stock price

We know what the payout of the option should be in the end of the second period. It is shown on the diagram below.

Call option price

Now we can determine the price of an option one period before (in up and down states). For the up state we have:

Pricing call option in up state

In the down state the option price should be zero because no matter where the stock moves, the price of the option is zero. Let’s confirm this:

Pricing call option in down state

Below you can see the updated option price diagram.

Call option price

Now we know that we can replicate a payout of a call option at the end of the second period with a portfolio that costs 17.93 in the up state and 0 in the down state (in the end of the first period). To determine the price of the option C_0 we need to find initial price of portfolio that will have a value of 17.93 in the up state and 0 in the down state. Basically we just repeat the same calculation.

Pricing call option

The initial price (at the beginning of the first period) of replicating portfolio is 10.27. If we buy this portfolio, we can be sure that we can rebalance it in the end of the first period to replicate the payout of the call option in the end of the second period. So by no-arbitrage principle this must be the price of the call option with strike price K=90 expiring at the end of the second period.

These are the basics of binomial pricing model. In real-world situations we need to decrease the length of time periods used and increase the total number of time periods. It can be shown that in the limit, as the length of time periods used goes to zero, binomial model converges to Black-Scholes model. So binomial pricing model is used in practice and in some cases it can be more accurate than Black-Scholes model.

In the next article I will describe a little bit more math and terminology behind binomial tree pricing model which will be useful to develop some intuitions about continuous time models.


Jupyter notebook with source code is available here.

If you have any questions, suggestions or corrections please post them in the comments. Thanks for reading.


References

[1] Financial calculus: an introduction to derivative pricing (Baxter and Rennie)

[2] https://www.math.snu.ac.kr/~hichoi/finmath/finance_lecture_2012_ch3.pdf

[3] https://quant.stackexchange.com/questions/35075/previsibility-in-binomial-representation-theorem

[4] https://en.wikipedia.org/wiki/Binomial_options_pricing_model

Leave a Reply

Your email address will not be published. Required fields are marked *