Tutorials › Stochastic Calculus › Calibrating Vasicek Parameters to Bond Data

Interest-Rate Models and Other Applications · Tutorial 502 of 600

Calibrating Vasicek Parameters to Bond Data

You will turn Vasicek bond yields into a constrained regression, profile the fit across mean-reversion values, and interpret price residuals and parameter trade-offs.

Advanced 11 min read

What You'll Learn

  • Write the Vasicek zero-coupon yield as a function of maturity and the model parameters.
  • Convert observed bond prices to continuously compounded yields before fitting.
  • Derive the uncentered least-squares solution when the regression has no intercept.
  • Impose the nonnegativity constraint on volatility variance and identify degenerate designs.
  • Interpret residuals on both yield and price scales.
  • Diagnose parameter trade-offs caused by nearly collinear maturity effects.

From Bond Prices to a Calibration Problem

Calibrating a short-rate model means choosing parameters so that its model bond prices match observed market prices as closely as a stated criterion requires. In the Vasicek model, fixing the mean-reversion speed makes the model yield linear in the long-run mean and the volatility variance. This gives a tractable inner least-squares problem, while the mean-reversion speed can be searched over separately. The resulting fit is a statistical approximation: residuals are informative, and a small residual alone does not show that the parameters are uniquely or reliably determined.

Use the risk-neutral Vasicek dynamics \(dr_t=\kappa(\theta-r_t)\,dt+\sigma\,dB_t\), where \(\kappa>0\) is the mean-reversion speed, \(\theta\) is the long-run mean, and \(\sigma\geq0\) is the diffusion coefficient. For pricing, these are parameters under the risk-neutral measure \(\mathbb{Q}\), not necessarily parameters under the real-world measure \(\mathbb{P}\). On the filtered probability space \((\Omega,\mathcal{F},(\mathcal{F}_t)_{t\geq0},\mathbb{P})\), suppose the model is considered under an equivalent pricing measure \(\mathbb{Q}\) under which \(B_t\) is Brownian motion. In integral form, its stochastic integral is an Ito integral; on each finite interval \([0,T]\), its integrand is progressively measurable and satisfies \(\mathbb{E}^{\mathbb{Q}}\int_0^T \sigma^2\,dt<\infty\). For constant \(\sigma\), this expectation is \(\sigma^2T\).

Let \(r_0\) be the current short rate and \(P(0,T)\) the time-zero price of a zero-coupon bond paying one unit at maturity \(T>0\). The affine Vasicek bond-pricing formula gives \(P(0,T)=A(T)e^{-B(T)r_0}\), with the following functions. This formula is the standard result from affine Vasicek bond pricing.

$$ B(T)=\frac{1-e^{-\kappa T}}{\kappa},\qquad \log A(T)=\left(\theta-\frac{\sigma^2}{2\kappa^2}\right)(B(T)-T)-\frac{\sigma^2B(T)^2}{4\kappa}. $$

The continuously compounded zero-coupon yield is \(y(T)=-\log P(0,T)/T\). Set \(v=\sigma^2\), so that the nonnegativity constraint is \(v\geq0\). Substituting the bond formula and collecting the coefficients of \(r_0,\theta,v\) gives

$$ y(T)=\frac{B(T)}{T}r_0+\frac{T-B(T)}{T}\theta+ \left(-\frac{T-B(T)}{2\kappa^2T}+\frac{B(T)^2}{4\kappa T}\right)v. $$

In particular, volatility enters the yield through a coefficient that can be negative; it should not be assumed in advance that increasing volatility raises every maturity yield. When \(r_0\) is observed and treated as fixed, define the maturity basis values \(x_i=(T_i-B(T_i))/T_i\) and \(z_i=-(T_i-B(T_i))/(2\kappa^2T_i)+B(T_i)^2/(4\kappa T_i)\). For observed yields \(q_i\), subtract the known short-rate contribution and write \(q_i-r_0B(T_i)/T_i=\theta x_i+v z_i+\varepsilon_i\). The residual \(\varepsilon_i\) is observed minus fitted yield. This is a regression with no free intercept: adding one would change the calibration problem.

Least Squares at a Fixed Mean-Reversion Speed

For a trial \(\kappa>0\), form the basis values at the observed maturities and minimize the sum of squared yield residuals over \(\theta\) and \(v\geq0\). The formulas below also describe a general two-column regression with no intercept. They are useful because the design columns may come from the Vasicek yield formula, but the regression calculation itself depends only on the columns and the data.

Theorem: Let \(q_i\) be the adjusted observations and \(x_i,z_i\) the two design columns, for \(i=1,\ldots,n\). Define \(J(b,c)=\sum_i(q_i-bx_i-cz_i)^2\), with \(c\geq0\). If \(U_{xx}=\sum_i x_i^2>0\) and \(D=U_{zz}-U_{xz}^2/U_{xx}>0\), where \(U_{xz}=\sum_i x_iz_i\), \(U_{zz}=\sum_i z_i^2\), \(U_{xq}=\sum_i x_iq_i\), and \(U_{zq}=\sum_i z_iq_i\), then the unique minimizer is \(c_*=\max(0,c_{\mathrm{unc}})\) and \(b_*=(U_{xq}-c_*U_{xz})/U_{xx}\), where \(c_{\mathrm{unc}}=(U_{zq}-U_{xz}U_{xq}/U_{xx})/D\).

Proof. Fix \(c\geq0\). Differentiating \(J(b,c)\) with respect to \(b\) gives \(-2\sum_i x_i(q_i-bx_i-cz_i)\). Since \(U_{xx}>0\), the unique minimizing value for this \(c\) is \(b(c)=(U_{xq}-cU_{xz})/U_{xx}\). Substitute this value. The residual vector is the part of \(q-cz\) perpendicular to \(x\), so the resulting objective is a constant independent of \(c\), plus \(Dc^2-2Nc\), where \(N=U_{zq}-U_{xz}U_{xq}/U_{xx}\). Because \(D>0\), completing the square gives \(Dc^2-2Nc=D(c-N/D)^2-N^2/D\). Its unconstrained minimum is at \(c=N/D=c_{\mathrm{unc}}\). Restricting to \(c\geq0\) therefore gives \(c_*=\max(0,c_{\mathrm{unc}})\); substituting back gives the stated \(b_*\). Strict positivity of \(U_{xx}\) and \(D\) makes the quadratic strictly convex in the two coefficients, so the minimizer is unique. \(\square\)

The sums in this theorem are uncentered sums, not centered covariances. Centering the columns would correspond to allowing a free intercept, which is absent from the model equation. If \(U_{xx}=0\), then every \(x_i=0\), so \(b\) has no effect on the objective and cannot be identified. If \(U_{xx}>0\) but \(D=0\), then the columns are proportional and the coefficients cannot in general be uniquely identified; one should minimize the original objective while reporting the resulting non-identifiability. These cases matter in actual calibrations, where a numerical optimizer cannot create information missing from the maturity data.

Worked Example: An Exact Uncentered Fit

For three adjusted observations, take \(x=(1,2,3)\), \(z=(1,0,1)\), and \(q=(3,4,7)\). Find the least-squares coefficients in \(q_i\approx bx_i+cz_i\), with \(c\geq0\), and check the fit.

First calculate every uncentered sum: \(U_{xx}=1^2+2^2+3^2=14\), \(U_{xz}=1\cdot1+2\cdot0+3\cdot1=4\), and \(U_{zz}=1^2+0^2+1^2=2\). Also, \(U_{xq}=1\cdot3+2\cdot4+3\cdot7=3+8+21=32\), while \(U_{zq}=1\cdot3+0\cdot4+1\cdot7=10\). Thus \(D=2-4^2/14=2-8/7=6/7\), and \(c_{\mathrm{unc}}=(10-4\cdot32/14)/(6/7)=(10-64/7)/(6/7)=1\). Since \(1\geq0\), \(c_*=1\). Then \(b_*=(32-1\cdot4)/14=2\).

Check: the fitted values are \(2\cdot1+1\cdot1=3\), \(2\cdot2+1\cdot0=4\), and \(2\cdot3+1\cdot1=7\). Each residual is zero, so the sum of squared residuals is zero, its smallest possible value.

Worked Example: Enforcing Nonnegative Variance

Take \(x=(1,0)\), \(z=(0,1)\), and adjusted observations \(q=(2,-1)\). Compute the constrained fit \(q_i\approx bx_i+cz_i\), \(c\geq0\).

Here \(U_{xx}=1\), \(U_{xz}=0\), \(U_{zz}=1\), \(U_{xq}=2\), and \(U_{zq}=-1\). Hence \(D=1\) and \(c_{\mathrm{unc}}=-1\). The constraint sets \(c_*=0\), and \(b_*=(2-0)/1=2\). The fitted values are \((2,0)\), giving residuals \(q_i-\widehat q_i=(0,-1)\) and sum of squared residuals \(0^2+(-1)^2=1\).

Check: for any \(c\geq0\), the first fitted value is \(b\) and the second is \(c\). The minimum of \((2-b)^2+(-1-c)^2\) is attained at \(b=2\) and at the allowed value \(c=0\), confirming the constrained answer. In a Vasicek calibration, this constraint is what prevents the fitted \(v\) from being negative; recover the volatility as \(\sigma=\sqrt{v}\).

Searching Across Mean-Reversion Speeds

The fixed-\(\kappa\) regression is an inner calculation. A practical procedure chooses a range of positive \(\kappa\) values, recomputes the maturity basis for each value, solves the constrained regression, and compares the minimized residual sums. One may then refine the search near the best candidates. This is a numerical calibration procedure, not a guarantee that the data identify a unique parameter triple. For a continuous objective on a prescribed closed, bounded interval of positive \(\kappa\), a minimum exists by the standard extreme value theorem; its proof is not needed for the regression calculation. If the search interval is open or unbounded, existence of a minimizing value should not be presumed.

For \(n\) observed bond prices \(P_i^{\mathrm{obs}}>0\) at maturities \(T_i>0\), convert prices to yields using \(q_i=-\log(P_i^{\mathrm{obs}})/T_i\). Positivity of prices makes this conversion well-defined. Yield least squares gives equal weight to squared yield errors. Price least squares instead minimizes squared errors in \(P_i\), and is a nonlinear objective in the parameters. These criteria need not select the same calibration: approximately, a small yield error \(\delta y_i\) produces price error \(\delta P_i\approx -T_iP_i\,\delta y_i\). Thus maturity and price levels affect how a yield discrepancy translates into price units.

Worked Example: Yield and Price Residuals

An observed two-year zero-coupon bond has continuously compounded yield \(0.0337\), and a fitted Vasicek model has yield \(0.03373823\). Find the observed and model prices and the observed-minus-model price residual.

For a continuously compounded yield \(y\), the unit-payment bond price is \(P=e^{-Ty}\). Therefore \(P^{\mathrm{obs}}=e^{-2(0.0337)}=e^{-0.0674}\approx0.93482120\). The fitted price is \(P^{\mathrm{model}}=e^{-2(0.03373823)}=e^{-0.06747646}\approx0.93474972\). Subtracting in the requested order gives \(P^{\mathrm{obs}}-P^{\mathrm{model}}\approx0.93482120-0.93474972=0.00007148\).

Check: the observed yield is lower than the model yield, so its price must be higher because \(e^{-Ty}\) decreases with \(y\) for \(T>0\). The positive price residual has the correct sign. The yield residual in the same observed-minus-model convention is \(0.0337-0.03373823=-0.00003823\); the price residual has the opposite sign, as expected.

Residuals and Parameter Trade-Offs

Residuals should be inspected by maturity, not only summarized by their total squared value. A systematic sequence of residuals—such as positive errors at short maturities and negative errors at long maturities—suggests that the fitted curve misses a shape feature. A single large residual may instead reflect a noisy or inconsistent quote. If observations have different precisions, a weighted least-squares objective \(\sum_i w_i(q_i-\widehat q_i)^2\), with specified weights \(w_i>0\), may be appropriate; the choice of weights changes the calibration target and should be reported.

Parameter trade-offs occur when the maturity basis columns have similar shapes. The following calculation shows how this appears in the regression geometry. Let \(x=(1,2,3)\) and \(z=(1,2.01,3)\). The squared length of the part of \(z\) perpendicular to \(x\) is \(D=U_{zz}-U_{xz}^2/U_{xx}\). Here \(U_{xx}=14\), \(U_{xz}=1+4.02+9=14.02\), and \(U_{zz}=1+4.0401+9=14.0401\), so \(D=14.0401-14.02^2/14=1/14000\). This small positive number means that the columns are close to proportional. The coefficients are technically identifiable, but small changes in the observations can produce comparatively large changes in the separate coefficient estimates. In a Vasicek fit, that warns against interpreting \(\theta\), \(\sigma\), or \(\kappa\) as precisely estimated solely because the fitted curve looks close to the data.

Common mistake: centering a regression that has no intercept. For the exact data in the first worked example, the correct uncentered fit is \(b=2,c=1\). If one instead uses centered covariance formulas, one is solving a different problem with an intercept. For example, the data satisfy \(q_i=2x_i+z_i\) exactly, but \(\bar q=14/3\); inserting that mean into a formula for an intercept-free coefficient does not preserve the exact fit. The correction is to use the uncentered sums \(U_{xx},U_{xz},U_{zz},U_{xq},U_{zq}\) in the profile formulas proved above.

Finally, distinguish model fit from model adequacy. A least-squares estimate is conditional on the selected pricing measure, model specification, observed maturities, residual scale, and fitting criterion. It does not by itself test whether the Vasicek assumptions are suitable, and it does not establish that the parameters will remain stable across dates. Report the fitted parameters alongside residuals and the maturity range used. If \(\kappa\) is searched over a range, report that range and whether the best fit occurs near its boundary.

Check Your Understanding

Use the definitions and formulas above to work through these calibration checks.

  1. For fixed \(\kappa\), identify the two regression columns and the adjusted observations when \(r_0\) is treated as known.
  2. Why must the fixed-\(\kappa\) least-squares formulas use uncentered sums when the yield equation has no intercept?
  3. If the unconstrained estimate of \(v=\sigma^2\) is negative, what is the constrained estimate, and what does that imply for the volatility estimate?
  4. Explain why a small value of \(D=U_{zz}-U_{xz}^2/U_{xx}\) can make the individual parameter estimates unstable even if the residual sum is small.
  5. For a positive maturity, which price is larger when two continuously compounded yields are compared, and how does that determine the sign of the price residual in the worked example?