Nelson-Siegel Model
The Nelson-Siegel Model is the three-factor curve of Nelson and Siegel (1987): a level, a slope and one hump, a parsimonious form that fits the usual shapes of the yield curve, upward-sloping, inverted and humped, with four parameters. Diebold and Li (2006) showed that its three factors read as the level, slope and curvature of the curve and are a good basis to forecast it.
The formula for the Nelson-Siegel Model builds the zero rate at a maturity of m years from the loadings of its factors. The slope loading \(L_{1}\) is 1 at the shortest maturity and decays to 0 at a speed set by the decay \(\tau_{1}\), and the curvature loading \(C_{1}\) is 0 at both ends and peaks in between:
\[L_{1} = \frac{1 - \exp\left(-\frac{m}{\tau_{1}}\right)}{\frac{m}{\tau_{1}}}\] \[C_{1} = L_{1} - \exp\left(-\frac{m}{\tau_{1}}\right)\]The continuously compounded zero rate y(m) is the level plus each factor times its loading:
\[y(m) = \beta_{0} + \beta_{1} \cdot L_{1} + \beta_{2} \cdot C_{1}\]Where \(\beta_{0}\) is the level, the zero rate at an infinite maturity, \(\beta_{1}\) the slope, so that the rate at the shortest maturity is \(\beta_{0} + \beta_{1}\), and \(\beta_{2}\) the curvature, a hump (or a trough when negative) that peaks at about 1.8 times \(\tau_{1}\) years. A negative \(\beta_{1}\) is an upward-sloping curve and a positive \(\beta_{1}\) an inverted one. With three factors the parameters are better identified than those of the Nelson-Siegel-Svensson Model, which makes them suited to tracking the level, slope and curvature over time, but a single hump can miss the shape of the long end.
A government yield curve is observed at a dozen maturities, each with its own noise. A parametric curve model describes the whole curve with a handful of parameters: it smooths out the noise of individual maturities, gives a yield for any maturity in between and turns the history of curves into a history of a few factors, the level, the slope and the curvature, which move with monetary policy and the economic cycle. The models here are fitted to continuously compounded zero-coupon rates, as central banks fit them, so their parameters are continuously compounded rates that compare with the published ones; the yields they give at chosen maturities are converted to annual compounding.
Also known as: NS, Nelson-Siegel curve, level slope curvature factors.
In the Finance Toolkit this is get_nelson_siegel_svensson with method="nelson_siegel", the same function as Nelson-Siegel-Svensson.
Example · 2026
Install the Finance Toolkit with pip install financetoolkit -U, then call get_nelson_siegel_svensson:
from financetoolkit import FixedIncome
fixedincome = FixedIncome(start_date='2026-10-19', end_date='2026-10-23')
fixedincome.get_nelson_siegel_svensson(method="nelson_siegel", countries='Germany')
| Parameter | Type | Description | Example |
|---|---|---|---|
countries | list[str] | str | The countries, see get_zero_coupon_curve. Defaults to “United States”. | ["United States", "Germany"] |
period | str | The frequency of the curves. Options are: “daily”, “weekly”, “monthly”. Defaults to “daily”. | "weekly" |
method | str | The model to fit. Options are: “svensson” (Nelson-Siegel-Svensson Model, the six parameters of Svensson, 1994) or “nelson_siegel” (Nelson-Siegel Model, the three factors of Nelson and Siegel, 1987). Defaults to “svensson”. | "svensson" |
maturities | list[float | str] | str | None | The maturities, in years or as labels such as “3M” and “10Y” (a list or a comma-separated string), to return the fitted zero-coupon yields at instead of the parameters. Defaults to None, which returns the parameters. | ["3M", "6M"] |
rounding | int | None | The number of decimals to round the results to. Defaults to None. | 2 |
transform | str | list[str] | None | Time series steps applied to the result in order, such as “sma:12” (moving average), “ema:12”, “std:12”, “zscore:60”, “percentile:120”, “yoy”, “pct_change:3,annualize:3”, “log”, “diff”, “cumsum” or “hp_trend” and “hp_cycle” (Hodrick-Prescott), along the dates of each series. A window needs that many periods of the result, so its first periods are empty. Defaults to None. | None |
show_columns | str | list[str] | None | The columns to keep, a name or a list of names, matched on every column level, or the rows when no column has those names (such as the line items of a financial statement). Names that do not exist are logged, and when none exist the result is returned in full. Defaults to None, which keeps every column. | None, which keeps every column |
Which returns:
| Item | Germany / Beta 0 | Germany / Beta 1 | Germany / Beta 2 | Germany / Tau 1 | Germany / Root Mean Squared Error |
|---|---|---|---|---|---|
| 2026-10-19 | 0.0413 | -0.0115 | -0.0111 | 3.1694 | 0.0002 |
| 2026-10-20 | 0.0000 | 0.0287 | 0.0776 | 30.3706 | 0.0002 |
| 2026-10-21 | 0.0000 | 0.0288 | 0.0769 | 30.6432 | 0.0002 |
| 2026-10-22 | 0.0017 | 0.0275 | 0.0708 | 31.6526 | 0.0002 |
| 2026-10-23 | 0.0399 | -0.0107 | -0.0106 | 3.1652 | 0.0002 |
5 rows
References
- Paper Nelson, C.R. and Siegel, A.F. (1987). “Parsimonious Modeling of Yield Curves.” The Journal of Business, 60(4), 473-489.
- Paper Diebold, F.X. and Li, C. (2006). “Forecasting the Term Structure of Government Bond Yields.” Journal of Econometrics, 130(2), 337-364.