Numerical Methods: Regression and Fitting#
Regression and fitting turn noisy data into a model that can be used between and beyond the data: a hedge ratio, a smile, a yield curve, the continuation value of an option. This section sets out linear regression, polynomial regression, non-linear regression and the choices that are common to all least-squares fits: weights, robust losses, regularisation and constraints. Regression is kept separate from optimisation. A fit is an optimisation, but the structure of least squares gives standard errors and a special set of methods, and the questions that matter are about what the data determine. It is written from a valuation control perspective, so each page ends with what to check.
Questions this section answers:
How is a hedge ratio or a proxy estimated, how uncertain is it, and what happens when the regressors move together? (Regression and Fitting, Part 1: Linear Regression)
How is the degree of a polynomial chosen, and why does a polynomial fail outside the data? (Regression and Fitting, Part 2: Polynomial Regression)
How is a model that is not linear in its parameters fitted, and how do we know what the data determine? (Regression and Fitting, Part 3: Non-linear Regression)
How do weights, robust losses, regularisation and constraints change a fit? (Regression and Fitting, Part 4: Least-Squares Fitting)
How the section is organised#
The four pages go from the simplest model to the most general. Linear regression has an exact solution with standard errors, and the hedge ratio shows what they mean. Polynomial regression is still linear in its coefficients and adds the choice of degree and basis, and the regression for a continuation value in a Monte Carlo. Non-linear regression needs an iterative method and shows the problems of local minima and weak identification on the Nelson-Siegel curve. The last page collects the choices that apply to every fit. The linear algebra that solves them is in Numerical Linear Algebra, the optimisers that non-linear fits use are in Optimisation, and the calibration of a model to prices, which draws on all of them, is in Calibration. Interpolation, which passes through the data and does not fit them, is in Numerical Methods: Interpolation.