Least Squares Method
The least squares method is a regression technique used to find the line (or curve) of best fit for a set of data points. It selects the model that minimizes the sum of the squared differences (residuals) between observed values and the values predicted by the model.
Key points
- Used to estimate the relationship between an independent variable (x, horizontal axis) and a dependent variable (y, vertical axis).
- Most commonly applied as ordinary (linear) least squares, producing a straight-line fit that minimizes the sum of squared vertical distances from points to the line.
- Nonlinear least-squares problems generally have no closed-form solution and are solved iteratively.
- Widely used across fields, including finance, to quantify relationships and make predictions.
How it works
- Plot paired observations (x, y) on a scatterplot.
- Choose a model form (most often a straight line).
- Compute the parameters that minimize the sum of squared residuals — the squared vertical distances from each point to the model.
- The resulting equation describes the estimated relationship between x and y and can be used for prediction and interpretation.
Important: In regression, the independent variable is placed on the x-axis and the dependent variable on the y-axis. The least squares criterion focuses on minimizing squared vertical deviations.
Explore More Resources
Advantages and disadvantages
Advantages
* Simple to apply and understand.
* Provides a clear quantitative summary of the relationship between two variables.
* Useful for prediction based on past observed relationships.
Disadvantages
* Only captures relationships between the specified variables; omitted variables can bias results.
* Sensitive to outliers, which can disproportionately affect the fitted line.
* Linear least squares assumes the chosen functional form is appropriate; misspecification can mislead.
Explore More Resources
Applications in finance
Financial analysts use least squares to quantify how one variable depends on another — for example, a stock’s returns versus market index returns or the sensitivity of a company’s share price to changes in commodity prices. The fitted line helps evaluate sensitivity and can inform forecasting and decision-making.
Examples
- Stock returns vs. index returns: Plot index returns as the independent variable and stock returns as the dependent variable. The least squares line estimates how much the stock tends to move for a given market move.
- Commodity exposure: An investor might use least squares to estimate how a mining company’s stock price responds to changes in the price of gold, aiding investment decisions.
Brief history
The method is commonly attributed to Carl Friedrich Gauss, who claimed to have formulated it in 1795.
Explore More Resources
Conclusion
The least squares method is a foundational regression tool for estimating relationships between variables and producing lines or curves of best fit. It is easy to implement and interpret but requires careful attention to model choice, omitted variables, and outliers.