Interest rates from cash flow discounting factors
Rates = disc2rate(Compounding,Disc,EndTimes) Rates = disc2rate(Compounding,Disc,EndTimes,StartTimes) [Rates,EndTimes,StartTimes] = disc2rate(Compounding,Disc,EndDates,StartDates,ValuationDate) [Rates,EndTimes,StartTimes] = disc2rate(Compounding,Disc,EndDates,StartDates,ValuationDate,Basis,EndMonthRule)
Usage 1: Interval points are input as times in periodic units.
Usage 2: ValuationDate
is
passed and interval points are input as dates.
 Scalar value representing the rate at which the input
zero rates were compounded when annualized. This argument determines
the formula for the discount factors (

 Number of points 

NoteWhen

 (Optional) 

NoteWhen

 (Optional) 
 Scalar value in serial date number form representing
the observation date of the investment horizons entered in 
 (Optional) Daycount basis of the instrument when using Usage 2. A vector of integers.
For more information, see basis. 
 (Optional) Endofmonth rule when using Usage 2. A vector. This rule applies only when 
Usage 1: Rates = disc2rate(Compounding,Disc,EndTimes)
or Rates
= disc2rate(Compounding, Disc,EndTimes,StartTimes)
where
interval points are input as times in periodic units.
Usage 2: [Rates,EndTimes,StartTimes]
= disc2rate(Compounding,Disc,EndDates,StartDates, ValuationDate)
or [Rates,EndTimes,StartTimes]
= disc2rate(Compounding,Disc,EndDates,StartDates,ValuationDate,Basis,
EndMonthRule)
where ValuationDate
is
passed and interval points are input as dates.
disc2rate
computes the
yields over a series of NPOINTS
time intervals
given the cash flow discounts over those intervals. NCURVES
different
rate curves can be translated at once if they have the same time structure.
The time intervals can represent a zero or a forward curve.
Rates
is an NPOINTS
byNCURVES
column
vector of yields in decimal form over the NPOINTS
time
intervals.
Specify the investment intervals with either input times (Usage 1) or input dates (Usage
2). Entering ValuationDate
invokes the
date interpretation; omitting ValuationDate
invokes
the default time interpretations.
For Usage 1:
StartTimes
is an NPOINTS
by1
column
vector of times starting the interval to discount over, measured in
periodic units.
EndTimes
is an NPOINTS
by1
column
vector of times ending the interval to discount over, measured in
periodic units.
For Usage 2:
StartDates
is an NPOINTS
by1
column
vector of serial dates starting the interval to discount over, measured
in days.
EndDates
is an NPOINTS
by1
column
vector of serial date ending the interval to discount over, measured
in days.
If Compounding = 365
(daily), StartTimes
and EndTimes
are
measured in days for Usage 2. Otherwise,
for Usage 1, the arguments contain
values, T
, computed from SIA semiannual time factors, Tsemi
,
by the formula T = Tsemi/2 * F
, where F
is
the compounding frequency.