Learn R Programming

SMFI5 (version 1.0)

est.cir: Estimates the parameters of the CIR model.

Description

Estimates the parameters of the CIR model

dr = alpha(beta-r)dt + sigma sqrt(r) dW

with market price of risk q(r) = q1/sqrt(r) +q2 sqrt(r). The time scale is in years and the units are percentages.

Usage

est.cir(data, method = "Hessian", days = 360, significanceLevel = 0.95)

Arguments

data
c(R,tau) (n x 2), with R: annual bonds yields in percentage, and tau: maturities in years.
method
'Hessian' (default), 'num'.
days
Number of days per year (default: 360).
significanceLevel
95%(default).

Value

theta
Parameters (alpha, beta, sigma, q1,q2) of the model.
error
Estimation errors for the given confidence level.
rimp
Implied spot rate.

References

Chapter 5 of 'Statistical Methods for Financial Engineering, B. Remillard, CRC Press, (2013).

Examples

Run this code
data(data.cir)
out = est.cir(data.cir,method='num')

Run the code above in your browser using DataLab