April 2019
Intermediate to advanced
426 pages
11h 13m
English
The Cox-Ingersoll-Ross (CIR) model is a one-factor model that was proposed to address the negative interest rates found in the Vasicek model. The process is given as follows:

The term
increases the standard deviation as the short-rate increases. Now the vasicek() function can be rewritten as the CIR model in Python:
In [ ]: import math import numpy as np def CIR(r0, K, theta, sigma, T=1.,N=10,seed=777): np.random.seed(seed) dt = T/float(N) rates = [r0] for i in range(N): dr = K*(theta-rates[-1])*dt + \ sigma*math.sqrt(rates[-1])*\ ...
Read now
Unlock full access