Nelson Siegel Model – Python Source Code

This program implements Nelson-Siegel and Nelson-Siegel-Svensson Yield Curve models.  Grid-based OLS is chosen as the parameter estimation algorithm.  Last update: change OLS to weighted OLS to improve model fitting performance.
  • Author: David Y
  • Date of release: 2019-11-13
  • Date of last update: 2019-12-01
  • Version: 1.1.0
  • License: BSD
  • Language: Python (tested in python 3.7.1)

click here to download

One Factor Interest Rate Model – C# Source Code

I have looked into the analytics for callable bonds lately [1][2].   The involves the use of an interest rate tree.  I thus implemented the Hull-White and Black-Karasinski one-factor short rate trees illustrated in Hull’s Options, Futures and Other Derivatives 6th Ed.  Ch28.7.   I included procedures to calibrate the rates tree using the premium of interest rate cap.   Once a tree is generated, it can be used to price and calculate the OAS for callable bonds (both fixed and floating rate with flexible call schedule).

  • Author: David Y
  • Date of first release:2014-08-03
  • Version: 1.0.0
  • License: BSD
  • Language: C# (tested in VS Express 2013 for Desktop)
  • Model: Hull-White and Black-Karasinski one-factor short rate trees
  • Dependence: ALGLIB numeric library (for optimisation code)

Click Here to Download