SlideShare a Scribd company logo
1 of 20
Download to read offline
Quantitative Finance
QF with MatLab
Mario Dell’Era
Scuola Superiore Sant’Anna
March 30, 2012
Mario Dell’Era Quantitative Finance
Interest rate sensitivity and bond portfolio
Immunization
Given a stream of cash flows occurring at times t0, · · · , tn the
duration of the stream is defined as
D =
PV(t0)t0 + · · · + PV(tn)tn
PV
where PV is the present value of the whole stream and PV(ti ) is the
present value of cash flow ci occurring at time ti , i = 0, 1, · · · , n.
PV =
n
k=1
ck
(1 + λ/m)k
Mario Dell’Era Quantitative Finance
When we consider a generic bond and use the yield as the discount
rate in computing the present values, we get Macaulay duration:
D =
n
k=1
k
m
ck
(1+λ/m)k
n
k=1
ck
(1+λ/m)k
where it is assumed that there are m coupon payments per year.
Mario Dell’Era Quantitative Finance
In order to see why duration is useful, let us compute the derivative of
the price with respect to yield:
dP
dλ
=
d
dλ
n
k=1
ck
(1 + λ/m)k
=
n
k=1
d
dλ
ck
(1 + /m)k
= −
n
k=1
k
m
ck
(1 + λ/m)k+1
If we define the modified duration DM = D/(1 + λ/m), we get:
dP
dλ
= −DM P(λ).
Mario Dell’Era Quantitative Finance
Thus we see that the modified duration is related to the slope of the
price-yield curve at a given point. This suggest the opportunity of
using a first order approximation:
δP −DM P(λ)δλ
Am even better approximation may be obtained by using a
second-order approximation. This may be done by defining the
convexity:
C =
1
P
d2
P
dλ2
.
Mario Dell’Era Quantitative Finance
It turns out that, for a bond with m coupons per year:
C =
1
P(1 + λ/m)2
n
k=1
k(k + 1)
m2
ck
(1 + λ/m)k
Note that the unit of measure of convexity is time squared. Convexity
is actually a desirable property of a bond, since a large convexity
implies a slower decrease in value when the required yield increases,
and a faster increase in value if the required yield decreases.
Mario Dell’Era Quantitative Finance
Using both convexity and duration, we have the second order
approximation:
δP(λ) −DM P(λ)(δλ) +
P(λ)C
2
(δλ)2
This relation is known in literature as immunization of bond portfolio.
Mario Dell’Era Quantitative Finance
Example
We may check the quality of the price change approximation based
on duration and convexity with a simple example. Let us consider a
stream of four cash flows (10, 10, 10, 10) occurring at times
t = 1, 2, 3, 4. We may compute the present values of this stream
under different yield values using MATLAB function pvvar.
Mario Dell’Era Quantitative Finance
>> cf= [10 10 10 10]
cf=
10 10 10 10
>> p1=pvvar([0, cf], 0.05 )
p1=
35.4595
>> p2=pvvar([0, cf], 0.055 )
p2=
35.0515
>>p2-p1
ans=
-0.4080
we see that increasing the yield by 0.005 results in a price drop of
0.4080.
Mario Dell’Era Quantitative Finance
Now we may compute the modified duration and the convexity using
the function cfdur and cfconv. The function cfdur returns both
Macauley and modified duration; for our purposes, we must pick up
the second output value:
>> [d1 dm]=cfdur(cf, 0.05)
d1=
2.4391
dm=
2.3229
>> cv= cfconv(cf, 0.05)
cv=
8.7397
>> −dm ∗ p1 ∗ 0.005
ans=
-0.4118
>> −dm ∗ p1 ∗ 0.005 + 0.5 ∗ cv ∗ p1 ∗ (0.005)2
and=
-0.4080
Mario Dell’Era Quantitative Finance
We see that at least for a small change in the yield, the first-order
approximation is satisfactory and the second-order approximation is
practically exact.This process is called immunization.
Mario Dell’Era Quantitative Finance
Example
A common problem in bond portfolio management is to shape a
portfolio with a given (modified) duration D and convexity C. Suppose
we have a set of tree bonds; we would like to find a set of portfolio
weights w1, w2 and w3, one for each bond, such that:
3
i=1
wi Di = D
3
i=1
wi Ci = C
3
i=1
wi = 1
where Ci and Di are the convexities and durations respectively
(i = 1, 2, 3).
Mario Dell’Era Quantitative Finance
% SET BOND FEATURES (bondimmum.m)
settle= ’28-Aug-2007’;
maturities=[’15-Jun-2012’ ; ’31-Oct-2017’ ; ’01-Mar-2027’];
couponRates=[0.07; 0.06 ; 0.08];
yields=[0.06 ; 0.07 ; 0.075];
Mario Dell’Era Quantitative Finance
% COMPUTE DURATIONS AND CONVEXITIES
durations=bnddury(yields, couponRates, settle, maturities);
convexities=bndconvy(yields, couponRate, settle, maturities);
Mario Dell’Era Quantitative Finance
% COMPUTE PORTFOLIO WEIGHTS
A=[duration’ convexities’ 1 1 1];
b=[10 160 1];
wieghts=A / b
Mario Dell’Era Quantitative Finance
weigths=
+0.1209
−0.4169
+1.2960
Mario Dell’Era Quantitative Finance
Interest-Rate Derivatives
Interest-rate Swaps
A swap is an arrangement between two parties, which agree to
exchange cash flows at predetermined dates in the future. In the
vanilla swap, one party will pay cash flows given by a fixed interest
rate applied to a nominal amount of money (the notional
principle).The other party will pay am amount given by a variable
interest rate, applied to a given interval of time (the tenure), on the
same notional principal. The net cash flow will depend on the level of
the future interest rates.
Mario Dell’Era Quantitative Finance
Bond Options
A call on a bond works more or less like a call option on a stock, with
a different underlying asset. In this case we have two maturities: the
maturity T of the option, at which the option can be exercised, and
the maturity T of the bond, where T < T. The payoff of the option will
depend on the bond price at T, which in turn depends on uncertain
interest rates.
Mario Dell’Era Quantitative Finance
Interest-rate Caps
A cap offers protections against a rise in interest rates. This may be
interesting to someone who wants to borrow money at variable rate.
A cap is a portfolio of caplets, applying to different time intervals in
the future. If L is a notional principal and RK is the cap rate, a caplet
applying to a time interval of length δt gives a payoff:
payoff = L × δt × max(0, R − RK )
where R is the interest rate prevailing for that interval. Should interest
rates rise in the future, the owner of the cap will receive a payoff
covering the payment interest above the cap rate. It can be shown
that caps are equivalent to portfolio of bond options.
Mario Dell’Era Quantitative Finance
Interest-rates Floors
A floor is similar to a cap, but it offers protection against a drop in
interest rates. The payoff of a floorlet is
payoff = L × δt × max(0, RK − R)
Mario Dell’Era Quantitative Finance

More Related Content

What's hot

What's hot (20)

Hedging & arbitrage
Hedging & arbitrageHedging & arbitrage
Hedging & arbitrage
 
Fixed income securities- Analysis and valuation
Fixed income securities- Analysis and valuationFixed income securities- Analysis and valuation
Fixed income securities- Analysis and valuation
 
Option cross rate
Option  cross rateOption  cross rate
Option cross rate
 
Financial derivatives ppt
Financial derivatives pptFinancial derivatives ppt
Financial derivatives ppt
 
Swaps (derivatives)
Swaps (derivatives)Swaps (derivatives)
Swaps (derivatives)
 
Future forward and option
Future forward and optionFuture forward and option
Future forward and option
 
Introduction To Bonds
Introduction To BondsIntroduction To Bonds
Introduction To Bonds
 
Black schole
Black scholeBlack schole
Black schole
 
Introduction to derivatives
Introduction to derivativesIntroduction to derivatives
Introduction to derivatives
 
Financial Derivatives in Risk Management
Financial Derivatives in Risk ManagementFinancial Derivatives in Risk Management
Financial Derivatives in Risk Management
 
financial intermediaries and its types
financial intermediaries and its typesfinancial intermediaries and its types
financial intermediaries and its types
 
Derivatives
DerivativesDerivatives
Derivatives
 
Options
OptionsOptions
Options
 
Foreign exchange risk
Foreign exchange riskForeign exchange risk
Foreign exchange risk
 
Derivative ppt
Derivative pptDerivative ppt
Derivative ppt
 
hedging strategy
hedging strategyhedging strategy
hedging strategy
 
FINANCIAL DERIVATIVES
FINANCIAL DERIVATIVES FINANCIAL DERIVATIVES
FINANCIAL DERIVATIVES
 
Derivatives market
Derivatives marketDerivatives market
Derivatives market
 
CURRENCY SWAP & INTREST RATE SWAP
CURRENCY SWAP & INTREST RATE SWAPCURRENCY SWAP & INTREST RATE SWAP
CURRENCY SWAP & INTREST RATE SWAP
 
Swaps
SwapsSwaps
Swaps
 

Viewers also liked

Stock return and_valuation
Stock return and_valuationStock return and_valuation
Stock return and_valuationumaganesh
 
Workshop 2013 of Quantitative Finance
Workshop 2013 of Quantitative FinanceWorkshop 2013 of Quantitative Finance
Workshop 2013 of Quantitative FinanceMario Dell'Era
 
Indian contract act 1872
Indian contract act 1872Indian contract act 1872
Indian contract act 1872umaganesh
 
Workshop 2012 of Quantitative Finance
Workshop 2012 of Quantitative FinanceWorkshop 2012 of Quantitative Finance
Workshop 2012 of Quantitative FinanceMario Dell'Era
 
The comparative study of finite difference method and monte carlo method for ...
The comparative study of finite difference method and monte carlo method for ...The comparative study of finite difference method and monte carlo method for ...
The comparative study of finite difference method and monte carlo method for ...Alexander Decker
 
Workshop 2011 of Quantitative Finance
Workshop 2011 of Quantitative FinanceWorkshop 2011 of Quantitative Finance
Workshop 2011 of Quantitative FinanceMario Dell'Era
 
Alternating direction-implicit-finite-difference-method-for-transient-2 d-hea...
Alternating direction-implicit-finite-difference-method-for-transient-2 d-hea...Alternating direction-implicit-finite-difference-method-for-transient-2 d-hea...
Alternating direction-implicit-finite-difference-method-for-transient-2 d-hea...Abimbola Ashaju
 
Global Derivatives 2014 - Did Basel put the final nail in the coffin of CSA D...
Global Derivatives 2014 - Did Basel put the final nail in the coffin of CSA D...Global Derivatives 2014 - Did Basel put the final nail in the coffin of CSA D...
Global Derivatives 2014 - Did Basel put the final nail in the coffin of CSA D...Alexandre Bon
 
RiskMinds - Did Basel & IOSCO put the final nail in the coffin of CSA-discoun...
RiskMinds - Did Basel & IOSCO put the final nail in the coffin of CSA-discoun...RiskMinds - Did Basel & IOSCO put the final nail in the coffin of CSA-discoun...
RiskMinds - Did Basel & IOSCO put the final nail in the coffin of CSA-discoun...Alexandre Bon
 
Dec2016 - Calculating and Managing Environmental Counterparty Risk
Dec2016 - Calculating and Managing Environmental Counterparty RiskDec2016 - Calculating and Managing Environmental Counterparty Risk
Dec2016 - Calculating and Managing Environmental Counterparty RiskJohn Rosengard
 
Long horizon simulations for counterparty risk
Long horizon simulations for counterparty risk Long horizon simulations for counterparty risk
Long horizon simulations for counterparty risk Alexandre Bon
 
Mine the Wine by Andrea Gigli
Mine the Wine by Andrea GigliMine the Wine by Andrea Gigli
Mine the Wine by Andrea GigliAndrea Gigli
 
From real to risk neutral probability measure for pricing and managing cva
From real to risk neutral probability measure for pricing and managing cvaFrom real to risk neutral probability measure for pricing and managing cva
From real to risk neutral probability measure for pricing and managing cvaAndrea Gigli
 
Lezione 1 - Introduzione al VBA per Excel
Lezione 1 - Introduzione al VBA per ExcelLezione 1 - Introduzione al VBA per Excel
Lezione 1 - Introduzione al VBA per ExcelGiovanni Della Lunga
 
Solution to Black-Scholes P.D.E. via Finite Difference Methods (MatLab)
Solution to Black-Scholes P.D.E. via Finite Difference Methods (MatLab)Solution to Black-Scholes P.D.E. via Finite Difference Methods (MatLab)
Solution to Black-Scholes P.D.E. via Finite Difference Methods (MatLab)Fynn McKay
 

Viewers also liked (20)

Bond Basics Seminar
Bond Basics SeminarBond Basics Seminar
Bond Basics Seminar
 
Stock return and_valuation
Stock return and_valuationStock return and_valuation
Stock return and_valuation
 
Workshop 2013 of Quantitative Finance
Workshop 2013 of Quantitative FinanceWorkshop 2013 of Quantitative Finance
Workshop 2013 of Quantitative Finance
 
E-QuanT(TimeSeries)
E-QuanT(TimeSeries)E-QuanT(TimeSeries)
E-QuanT(TimeSeries)
 
Metodi numerici
Metodi numericiMetodi numerici
Metodi numerici
 
Indian contract act 1872
Indian contract act 1872Indian contract act 1872
Indian contract act 1872
 
Workshop 2012 of Quantitative Finance
Workshop 2012 of Quantitative FinanceWorkshop 2012 of Quantitative Finance
Workshop 2012 of Quantitative Finance
 
The comparative study of finite difference method and monte carlo method for ...
The comparative study of finite difference method and monte carlo method for ...The comparative study of finite difference method and monte carlo method for ...
The comparative study of finite difference method and monte carlo method for ...
 
Workshop 2011 of Quantitative Finance
Workshop 2011 of Quantitative FinanceWorkshop 2011 of Quantitative Finance
Workshop 2011 of Quantitative Finance
 
Alternating direction-implicit-finite-difference-method-for-transient-2 d-hea...
Alternating direction-implicit-finite-difference-method-for-transient-2 d-hea...Alternating direction-implicit-finite-difference-method-for-transient-2 d-hea...
Alternating direction-implicit-finite-difference-method-for-transient-2 d-hea...
 
American Options with Monte Carlo
American Options with Monte CarloAmerican Options with Monte Carlo
American Options with Monte Carlo
 
Global Derivatives 2014 - Did Basel put the final nail in the coffin of CSA D...
Global Derivatives 2014 - Did Basel put the final nail in the coffin of CSA D...Global Derivatives 2014 - Did Basel put the final nail in the coffin of CSA D...
Global Derivatives 2014 - Did Basel put the final nail in the coffin of CSA D...
 
RiskMinds - Did Basel & IOSCO put the final nail in the coffin of CSA-discoun...
RiskMinds - Did Basel & IOSCO put the final nail in the coffin of CSA-discoun...RiskMinds - Did Basel & IOSCO put the final nail in the coffin of CSA-discoun...
RiskMinds - Did Basel & IOSCO put the final nail in the coffin of CSA-discoun...
 
Dec2016 - Calculating and Managing Environmental Counterparty Risk
Dec2016 - Calculating and Managing Environmental Counterparty RiskDec2016 - Calculating and Managing Environmental Counterparty Risk
Dec2016 - Calculating and Managing Environmental Counterparty Risk
 
Long horizon simulations for counterparty risk
Long horizon simulations for counterparty risk Long horizon simulations for counterparty risk
Long horizon simulations for counterparty risk
 
Mine the Wine by Andrea Gigli
Mine the Wine by Andrea GigliMine the Wine by Andrea Gigli
Mine the Wine by Andrea Gigli
 
Chapter1
Chapter1Chapter1
Chapter1
 
From real to risk neutral probability measure for pricing and managing cva
From real to risk neutral probability measure for pricing and managing cvaFrom real to risk neutral probability measure for pricing and managing cva
From real to risk neutral probability measure for pricing and managing cva
 
Lezione 1 - Introduzione al VBA per Excel
Lezione 1 - Introduzione al VBA per ExcelLezione 1 - Introduzione al VBA per Excel
Lezione 1 - Introduzione al VBA per Excel
 
Solution to Black-Scholes P.D.E. via Finite Difference Methods (MatLab)
Solution to Black-Scholes P.D.E. via Finite Difference Methods (MatLab)Solution to Black-Scholes P.D.E. via Finite Difference Methods (MatLab)
Solution to Black-Scholes P.D.E. via Finite Difference Methods (MatLab)
 

Similar to Duration and Convexity

Lecture 4 2012 valuation and risk
Lecture 4 2012   valuation and riskLecture 4 2012   valuation and risk
Lecture 4 2012 valuation and riskAimey324
 
Session8 Koch6
Session8 Koch6Session8 Koch6
Session8 Koch6ukabuka
 
Macrodynamics of Debt-Financed Investment-Led Growth with Interest Rate Rules
Macrodynamics of Debt-Financed Investment-Led Growth with Interest Rate RulesMacrodynamics of Debt-Financed Investment-Led Growth with Interest Rate Rules
Macrodynamics of Debt-Financed Investment-Led Growth with Interest Rate Rulespkconference
 
CDS and Loss function: CDO Tranches
CDS and Loss function: CDO TranchesCDS and Loss function: CDO Tranches
CDS and Loss function: CDO TranchesBank Industry
 
1- Consider the model of liquidity and financial intermediation presen.docx
1- Consider the model of liquidity and financial intermediation presen.docx1- Consider the model of liquidity and financial intermediation presen.docx
1- Consider the model of liquidity and financial intermediation presen.docxfitzlikv
 
Quantitative Methods for Counterparty Risk
Quantitative Methods for Counterparty RiskQuantitative Methods for Counterparty Risk
Quantitative Methods for Counterparty RiskVolatility
 
Derivatives pricing and Malliavin Calculus
Derivatives pricing and Malliavin CalculusDerivatives pricing and Malliavin Calculus
Derivatives pricing and Malliavin CalculusHugo Delatte
 
risk measurement
risk measurementrisk measurement
risk measurementroloderi
 
7_Analysing and Interpreting the Yield Curve.ppt
7_Analysing and Interpreting the Yield Curve.ppt7_Analysing and Interpreting the Yield Curve.ppt
7_Analysing and Interpreting the Yield Curve.pptMurat Öztürkmen
 
Fair valuation of participating life insurance contracts with jump risk
Fair valuation of participating life insurance contracts with jump riskFair valuation of participating life insurance contracts with jump risk
Fair valuation of participating life insurance contracts with jump riskAlex Kouam
 
BB_6_Futures & Options_Hull_Chap_6.pptx
BB_6_Futures & Options_Hull_Chap_6.pptxBB_6_Futures & Options_Hull_Chap_6.pptx
BB_6_Futures & Options_Hull_Chap_6.pptxIbrahimKhatatbeh5
 
Ec2204 tutorial 2(2)
Ec2204 tutorial 2(2)Ec2204 tutorial 2(2)
Ec2204 tutorial 2(2)dannygriff1
 
Bond price and yield pdf
Bond price and yield pdfBond price and yield pdf
Bond price and yield pdfDavid Keck
 
Copula-Based Model for the Term Structure of CDO Tranches
Copula-Based Model for the Term Structure of CDO TranchesCopula-Based Model for the Term Structure of CDO Tranches
Copula-Based Model for the Term Structure of CDO Tranchesfinancedude
 
Homework 51)a) the IS curve ln Yt= ln Y(t+1) – (1Ɵ)rtso th.docx
Homework 51)a) the IS curve ln Yt= ln Y(t+1) – (1Ɵ)rtso th.docxHomework 51)a) the IS curve ln Yt= ln Y(t+1) – (1Ɵ)rtso th.docx
Homework 51)a) the IS curve ln Yt= ln Y(t+1) – (1Ɵ)rtso th.docxadampcarr67227
 
Affine cascade models for term structure dynamics of sovereign yield curves
Affine cascade models for term structure dynamics of sovereign yield curvesAffine cascade models for term structure dynamics of sovereign yield curves
Affine cascade models for term structure dynamics of sovereign yield curvesLAURAMICHAELA
 
Basic of pricing 2
Basic of pricing 2Basic of pricing 2
Basic of pricing 2Ilya Gikhman
 

Similar to Duration and Convexity (20)

Lecture 4 2012 valuation and risk
Lecture 4 2012   valuation and riskLecture 4 2012   valuation and risk
Lecture 4 2012 valuation and risk
 
Chp15 Interest Rate Derivatives.ppt
Chp15 Interest Rate Derivatives.pptChp15 Interest Rate Derivatives.ppt
Chp15 Interest Rate Derivatives.ppt
 
Duration model
Duration modelDuration model
Duration model
 
Session8 Koch6
Session8 Koch6Session8 Koch6
Session8 Koch6
 
Macrodynamics of Debt-Financed Investment-Led Growth with Interest Rate Rules
Macrodynamics of Debt-Financed Investment-Led Growth with Interest Rate RulesMacrodynamics of Debt-Financed Investment-Led Growth with Interest Rate Rules
Macrodynamics of Debt-Financed Investment-Led Growth with Interest Rate Rules
 
CDS and Loss function: CDO Tranches
CDS and Loss function: CDO TranchesCDS and Loss function: CDO Tranches
CDS and Loss function: CDO Tranches
 
1- Consider the model of liquidity and financial intermediation presen.docx
1- Consider the model of liquidity and financial intermediation presen.docx1- Consider the model of liquidity and financial intermediation presen.docx
1- Consider the model of liquidity and financial intermediation presen.docx
 
Quantitative Methods for Counterparty Risk
Quantitative Methods for Counterparty RiskQuantitative Methods for Counterparty Risk
Quantitative Methods for Counterparty Risk
 
Derivatives pricing and Malliavin Calculus
Derivatives pricing and Malliavin CalculusDerivatives pricing and Malliavin Calculus
Derivatives pricing and Malliavin Calculus
 
risk measurement
risk measurementrisk measurement
risk measurement
 
7_Analysing and Interpreting the Yield Curve.ppt
7_Analysing and Interpreting the Yield Curve.ppt7_Analysing and Interpreting the Yield Curve.ppt
7_Analysing and Interpreting the Yield Curve.ppt
 
Fair valuation of participating life insurance contracts with jump risk
Fair valuation of participating life insurance contracts with jump riskFair valuation of participating life insurance contracts with jump risk
Fair valuation of participating life insurance contracts with jump risk
 
Slides1
Slides1Slides1
Slides1
 
BB_6_Futures & Options_Hull_Chap_6.pptx
BB_6_Futures & Options_Hull_Chap_6.pptxBB_6_Futures & Options_Hull_Chap_6.pptx
BB_6_Futures & Options_Hull_Chap_6.pptx
 
Ec2204 tutorial 2(2)
Ec2204 tutorial 2(2)Ec2204 tutorial 2(2)
Ec2204 tutorial 2(2)
 
Bond price and yield pdf
Bond price and yield pdfBond price and yield pdf
Bond price and yield pdf
 
Copula-Based Model for the Term Structure of CDO Tranches
Copula-Based Model for the Term Structure of CDO TranchesCopula-Based Model for the Term Structure of CDO Tranches
Copula-Based Model for the Term Structure of CDO Tranches
 
Homework 51)a) the IS curve ln Yt= ln Y(t+1) – (1Ɵ)rtso th.docx
Homework 51)a) the IS curve ln Yt= ln Y(t+1) – (1Ɵ)rtso th.docxHomework 51)a) the IS curve ln Yt= ln Y(t+1) – (1Ɵ)rtso th.docx
Homework 51)a) the IS curve ln Yt= ln Y(t+1) – (1Ɵ)rtso th.docx
 
Affine cascade models for term structure dynamics of sovereign yield curves
Affine cascade models for term structure dynamics of sovereign yield curvesAffine cascade models for term structure dynamics of sovereign yield curves
Affine cascade models for term structure dynamics of sovereign yield curves
 
Basic of pricing 2
Basic of pricing 2Basic of pricing 2
Basic of pricing 2
 

Recently uploaded

Introduction to Nonprofit Accounting: The Basics
Introduction to Nonprofit Accounting: The BasicsIntroduction to Nonprofit Accounting: The Basics
Introduction to Nonprofit Accounting: The BasicsTechSoup
 
Ecological Succession. ( ECOSYSTEM, B. Pharmacy, 1st Year, Sem-II, Environmen...
Ecological Succession. ( ECOSYSTEM, B. Pharmacy, 1st Year, Sem-II, Environmen...Ecological Succession. ( ECOSYSTEM, B. Pharmacy, 1st Year, Sem-II, Environmen...
Ecological Succession. ( ECOSYSTEM, B. Pharmacy, 1st Year, Sem-II, Environmen...Shubhangi Sonawane
 
Gardella_PRCampaignConclusion Pitch Letter
Gardella_PRCampaignConclusion Pitch LetterGardella_PRCampaignConclusion Pitch Letter
Gardella_PRCampaignConclusion Pitch LetterMateoGardella
 
Unit-IV- Pharma. Marketing Channels.pptx
Unit-IV- Pharma. Marketing Channels.pptxUnit-IV- Pharma. Marketing Channels.pptx
Unit-IV- Pharma. Marketing Channels.pptxVishalSingh1417
 
Gardella_Mateo_IntellectualProperty.pdf.
Gardella_Mateo_IntellectualProperty.pdf.Gardella_Mateo_IntellectualProperty.pdf.
Gardella_Mateo_IntellectualProperty.pdf.MateoGardella
 
APM Welcome, APM North West Network Conference, Synergies Across Sectors
APM Welcome, APM North West Network Conference, Synergies Across SectorsAPM Welcome, APM North West Network Conference, Synergies Across Sectors
APM Welcome, APM North West Network Conference, Synergies Across SectorsAssociation for Project Management
 
Unit-IV; Professional Sales Representative (PSR).pptx
Unit-IV; Professional Sales Representative (PSR).pptxUnit-IV; Professional Sales Representative (PSR).pptx
Unit-IV; Professional Sales Representative (PSR).pptxVishalSingh1417
 
Holdier Curriculum Vitae (April 2024).pdf
Holdier Curriculum Vitae (April 2024).pdfHoldier Curriculum Vitae (April 2024).pdf
Holdier Curriculum Vitae (April 2024).pdfagholdier
 
Application orientated numerical on hev.ppt
Application orientated numerical on hev.pptApplication orientated numerical on hev.ppt
Application orientated numerical on hev.pptRamjanShidvankar
 
PROCESS RECORDING FORMAT.docx
PROCESS      RECORDING        FORMAT.docxPROCESS      RECORDING        FORMAT.docx
PROCESS RECORDING FORMAT.docxPoojaSen20
 
1029 - Danh muc Sach Giao Khoa 10 . pdf
1029 -  Danh muc Sach Giao Khoa 10 . pdf1029 -  Danh muc Sach Giao Khoa 10 . pdf
1029 - Danh muc Sach Giao Khoa 10 . pdfQucHHunhnh
 
Accessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impactAccessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impactdawncurless
 
Making and Justifying Mathematical Decisions.pdf
Making and Justifying Mathematical Decisions.pdfMaking and Justifying Mathematical Decisions.pdf
Making and Justifying Mathematical Decisions.pdfChris Hunter
 
The basics of sentences session 2pptx copy.pptx
The basics of sentences session 2pptx copy.pptxThe basics of sentences session 2pptx copy.pptx
The basics of sentences session 2pptx copy.pptxheathfieldcps1
 
Class 11th Physics NEET formula sheet pdf
Class 11th Physics NEET formula sheet pdfClass 11th Physics NEET formula sheet pdf
Class 11th Physics NEET formula sheet pdfAyushMahapatra5
 
Key note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdfKey note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdfAdmir Softic
 
Web & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdfWeb & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdfJayanti Pande
 

Recently uploaded (20)

Introduction to Nonprofit Accounting: The Basics
Introduction to Nonprofit Accounting: The BasicsIntroduction to Nonprofit Accounting: The Basics
Introduction to Nonprofit Accounting: The Basics
 
Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"
Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"
Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"
 
Ecological Succession. ( ECOSYSTEM, B. Pharmacy, 1st Year, Sem-II, Environmen...
Ecological Succession. ( ECOSYSTEM, B. Pharmacy, 1st Year, Sem-II, Environmen...Ecological Succession. ( ECOSYSTEM, B. Pharmacy, 1st Year, Sem-II, Environmen...
Ecological Succession. ( ECOSYSTEM, B. Pharmacy, 1st Year, Sem-II, Environmen...
 
Gardella_PRCampaignConclusion Pitch Letter
Gardella_PRCampaignConclusion Pitch LetterGardella_PRCampaignConclusion Pitch Letter
Gardella_PRCampaignConclusion Pitch Letter
 
Unit-IV- Pharma. Marketing Channels.pptx
Unit-IV- Pharma. Marketing Channels.pptxUnit-IV- Pharma. Marketing Channels.pptx
Unit-IV- Pharma. Marketing Channels.pptx
 
Gardella_Mateo_IntellectualProperty.pdf.
Gardella_Mateo_IntellectualProperty.pdf.Gardella_Mateo_IntellectualProperty.pdf.
Gardella_Mateo_IntellectualProperty.pdf.
 
APM Welcome, APM North West Network Conference, Synergies Across Sectors
APM Welcome, APM North West Network Conference, Synergies Across SectorsAPM Welcome, APM North West Network Conference, Synergies Across Sectors
APM Welcome, APM North West Network Conference, Synergies Across Sectors
 
Unit-IV; Professional Sales Representative (PSR).pptx
Unit-IV; Professional Sales Representative (PSR).pptxUnit-IV; Professional Sales Representative (PSR).pptx
Unit-IV; Professional Sales Representative (PSR).pptx
 
Holdier Curriculum Vitae (April 2024).pdf
Holdier Curriculum Vitae (April 2024).pdfHoldier Curriculum Vitae (April 2024).pdf
Holdier Curriculum Vitae (April 2024).pdf
 
Application orientated numerical on hev.ppt
Application orientated numerical on hev.pptApplication orientated numerical on hev.ppt
Application orientated numerical on hev.ppt
 
PROCESS RECORDING FORMAT.docx
PROCESS      RECORDING        FORMAT.docxPROCESS      RECORDING        FORMAT.docx
PROCESS RECORDING FORMAT.docx
 
Mehran University Newsletter Vol-X, Issue-I, 2024
Mehran University Newsletter Vol-X, Issue-I, 2024Mehran University Newsletter Vol-X, Issue-I, 2024
Mehran University Newsletter Vol-X, Issue-I, 2024
 
1029 - Danh muc Sach Giao Khoa 10 . pdf
1029 -  Danh muc Sach Giao Khoa 10 . pdf1029 -  Danh muc Sach Giao Khoa 10 . pdf
1029 - Danh muc Sach Giao Khoa 10 . pdf
 
Accessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impactAccessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impact
 
Making and Justifying Mathematical Decisions.pdf
Making and Justifying Mathematical Decisions.pdfMaking and Justifying Mathematical Decisions.pdf
Making and Justifying Mathematical Decisions.pdf
 
The basics of sentences session 2pptx copy.pptx
The basics of sentences session 2pptx copy.pptxThe basics of sentences session 2pptx copy.pptx
The basics of sentences session 2pptx copy.pptx
 
Class 11th Physics NEET formula sheet pdf
Class 11th Physics NEET formula sheet pdfClass 11th Physics NEET formula sheet pdf
Class 11th Physics NEET formula sheet pdf
 
Advance Mobile Application Development class 07
Advance Mobile Application Development class 07Advance Mobile Application Development class 07
Advance Mobile Application Development class 07
 
Key note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdfKey note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdf
 
Web & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdfWeb & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdf
 

Duration and Convexity

  • 1. Quantitative Finance QF with MatLab Mario Dell’Era Scuola Superiore Sant’Anna March 30, 2012 Mario Dell’Era Quantitative Finance
  • 2. Interest rate sensitivity and bond portfolio Immunization Given a stream of cash flows occurring at times t0, · · · , tn the duration of the stream is defined as D = PV(t0)t0 + · · · + PV(tn)tn PV where PV is the present value of the whole stream and PV(ti ) is the present value of cash flow ci occurring at time ti , i = 0, 1, · · · , n. PV = n k=1 ck (1 + λ/m)k Mario Dell’Era Quantitative Finance
  • 3. When we consider a generic bond and use the yield as the discount rate in computing the present values, we get Macaulay duration: D = n k=1 k m ck (1+λ/m)k n k=1 ck (1+λ/m)k where it is assumed that there are m coupon payments per year. Mario Dell’Era Quantitative Finance
  • 4. In order to see why duration is useful, let us compute the derivative of the price with respect to yield: dP dλ = d dλ n k=1 ck (1 + λ/m)k = n k=1 d dλ ck (1 + /m)k = − n k=1 k m ck (1 + λ/m)k+1 If we define the modified duration DM = D/(1 + λ/m), we get: dP dλ = −DM P(λ). Mario Dell’Era Quantitative Finance
  • 5. Thus we see that the modified duration is related to the slope of the price-yield curve at a given point. This suggest the opportunity of using a first order approximation: δP −DM P(λ)δλ Am even better approximation may be obtained by using a second-order approximation. This may be done by defining the convexity: C = 1 P d2 P dλ2 . Mario Dell’Era Quantitative Finance
  • 6. It turns out that, for a bond with m coupons per year: C = 1 P(1 + λ/m)2 n k=1 k(k + 1) m2 ck (1 + λ/m)k Note that the unit of measure of convexity is time squared. Convexity is actually a desirable property of a bond, since a large convexity implies a slower decrease in value when the required yield increases, and a faster increase in value if the required yield decreases. Mario Dell’Era Quantitative Finance
  • 7. Using both convexity and duration, we have the second order approximation: δP(λ) −DM P(λ)(δλ) + P(λ)C 2 (δλ)2 This relation is known in literature as immunization of bond portfolio. Mario Dell’Era Quantitative Finance
  • 8. Example We may check the quality of the price change approximation based on duration and convexity with a simple example. Let us consider a stream of four cash flows (10, 10, 10, 10) occurring at times t = 1, 2, 3, 4. We may compute the present values of this stream under different yield values using MATLAB function pvvar. Mario Dell’Era Quantitative Finance
  • 9. >> cf= [10 10 10 10] cf= 10 10 10 10 >> p1=pvvar([0, cf], 0.05 ) p1= 35.4595 >> p2=pvvar([0, cf], 0.055 ) p2= 35.0515 >>p2-p1 ans= -0.4080 we see that increasing the yield by 0.005 results in a price drop of 0.4080. Mario Dell’Era Quantitative Finance
  • 10. Now we may compute the modified duration and the convexity using the function cfdur and cfconv. The function cfdur returns both Macauley and modified duration; for our purposes, we must pick up the second output value: >> [d1 dm]=cfdur(cf, 0.05) d1= 2.4391 dm= 2.3229 >> cv= cfconv(cf, 0.05) cv= 8.7397 >> −dm ∗ p1 ∗ 0.005 ans= -0.4118 >> −dm ∗ p1 ∗ 0.005 + 0.5 ∗ cv ∗ p1 ∗ (0.005)2 and= -0.4080 Mario Dell’Era Quantitative Finance
  • 11. We see that at least for a small change in the yield, the first-order approximation is satisfactory and the second-order approximation is practically exact.This process is called immunization. Mario Dell’Era Quantitative Finance
  • 12. Example A common problem in bond portfolio management is to shape a portfolio with a given (modified) duration D and convexity C. Suppose we have a set of tree bonds; we would like to find a set of portfolio weights w1, w2 and w3, one for each bond, such that: 3 i=1 wi Di = D 3 i=1 wi Ci = C 3 i=1 wi = 1 where Ci and Di are the convexities and durations respectively (i = 1, 2, 3). Mario Dell’Era Quantitative Finance
  • 13. % SET BOND FEATURES (bondimmum.m) settle= ’28-Aug-2007’; maturities=[’15-Jun-2012’ ; ’31-Oct-2017’ ; ’01-Mar-2027’]; couponRates=[0.07; 0.06 ; 0.08]; yields=[0.06 ; 0.07 ; 0.075]; Mario Dell’Era Quantitative Finance
  • 14. % COMPUTE DURATIONS AND CONVEXITIES durations=bnddury(yields, couponRates, settle, maturities); convexities=bndconvy(yields, couponRate, settle, maturities); Mario Dell’Era Quantitative Finance
  • 15. % COMPUTE PORTFOLIO WEIGHTS A=[duration’ convexities’ 1 1 1]; b=[10 160 1]; wieghts=A / b Mario Dell’Era Quantitative Finance
  • 17. Interest-Rate Derivatives Interest-rate Swaps A swap is an arrangement between two parties, which agree to exchange cash flows at predetermined dates in the future. In the vanilla swap, one party will pay cash flows given by a fixed interest rate applied to a nominal amount of money (the notional principle).The other party will pay am amount given by a variable interest rate, applied to a given interval of time (the tenure), on the same notional principal. The net cash flow will depend on the level of the future interest rates. Mario Dell’Era Quantitative Finance
  • 18. Bond Options A call on a bond works more or less like a call option on a stock, with a different underlying asset. In this case we have two maturities: the maturity T of the option, at which the option can be exercised, and the maturity T of the bond, where T < T. The payoff of the option will depend on the bond price at T, which in turn depends on uncertain interest rates. Mario Dell’Era Quantitative Finance
  • 19. Interest-rate Caps A cap offers protections against a rise in interest rates. This may be interesting to someone who wants to borrow money at variable rate. A cap is a portfolio of caplets, applying to different time intervals in the future. If L is a notional principal and RK is the cap rate, a caplet applying to a time interval of length δt gives a payoff: payoff = L × δt × max(0, R − RK ) where R is the interest rate prevailing for that interval. Should interest rates rise in the future, the owner of the cap will receive a payoff covering the payment interest above the cap rate. It can be shown that caps are equivalent to portfolio of bond options. Mario Dell’Era Quantitative Finance
  • 20. Interest-rates Floors A floor is similar to a cap, but it offers protection against a drop in interest rates. The payoff of a floorlet is payoff = L × δt × max(0, RK − R) Mario Dell’Era Quantitative Finance