NS function

Zero Rates for Nelson--Siegel--Svensson Model

Zero Rates for Nelson--Siegel--Svensson Model

Compute zero yields for Nelson--Siegel (NS )/Nelson--Siegel--Svensson (NSS ) model.

NS(param, tm) NSS(param, tm)

Arguments

  • param: a vector. For NS : beta1beta1, beta2beta2, beta3beta3, lambdalambda. For NSS : a vector: beta1beta1, beta2beta2, beta3beta3, beta4beta4, lambda1lambda1, lambda2lambda2.
  • tm: a vector of maturities

Details

See Chapter 14 in Gilli/Maringer/Schumann (2011).

Maturities (tm) need to be given in time (not dates).

Returns

The function returns a vector of length length(tm).

References

Gilli, M. and Grosse, S. and Schumann, E. (2010) Calibrating the Nelson-Siegel-Svensson model, COMISEF Working Paper Series No. 031. https://enricoschumann.net/COMISEF/wps031.pdf

Gilli, M., Maringer, D. and Schumann, E. (2019) Numerical Methods and Optimization in Finance. 2nd edition. Elsevier. tools:::Rd_expr_doi("10.1016/C2017-0-01621-X")

Gilli, M. and Schumann, E. (2010) A Note on Good Starting Values in Numerical Optimisation, COMISEF Working Paper Series No. 044. https://enricoschumann.net/COMISEF/wps044.pdf

Nelson, C.R. and Siegel, A.F. (1987) Parsimonious Modeling of Yield Curves. Journal of Business, 60 (4), pp. 473--489.

Schumann, E. (2023) Financial Optimisation with R (NMOF Manual). https://enricoschumann.net/NMOF.htm#NMOFmanual

Svensson, L.E. (1994) Estimating and Interpreting Forward Interest Rates: Sweden 1992--1994. IMF Working Paper 94/114.

Author(s)

Enrico Schumann

See Also

NSf, NSSf

Examples

tm <- c(c(1, 3, 6, 9) / 12, 1:10) ## in years param <- c(6, 3, 8, 1) yM <- NS(param, tm) plot(tm, yM, xlab = "maturity in years", ylab = "yield in percent") param <- c(6, 3, 5, -5, 1, 3) yM <- NSS(param, tm) plot(tm, yM, xlab = "maturity in years", ylab = "yield in percent")