To view the demo, click here. Note: To run the demo you may first need to install a Java2 plug-in. This link provides information on downloading Java.
BCS has been involved in numerous technical projects that involve the analysis of data using "curve fitting" or "regression" techniques. These applications have ranged from deconvolution problems in seismic processing to magnetic signature determination of naval vessels. The algorithms employed have varied from general purpose schemes to novel customized methods developed by BCS. A very simple regression example would involve fitting a straight line to observed data that links just two variables; a straight-line relationship can be valuable in summarizing the dependence of one variable on another, or in indicating a trend in a time series.
Many introductory science textbooks include a discussion of the method of least-squares (LS), which was proposed about 200 years ago, for determining the "best" straight line fit to a set of data points plotted on a graph. However, some 50 years earlier a less familiar criterion for "best" straight line fitting was proposed; it is the method of least absolute values (LAV). Briefly, if we define the residuals as the vertical distances (positive or negative) from a fitted line to the data points, the LS straight line minimizes the sum of all the squared residuals, whereas the LAV straight line minimizes the sum of the absolute values (sizes) of these residuals. The demo provided (which requires that your browser be Java-enabled) illustrates both LS and LAV straight line fits to user-input data; data points can be added, moved and deleted interactively.
You might like to experiment with this demo in order to evaluate the sensitivity of straight line fits to different types of data. For example, using the "Add Points" option provided, input several points that lie approximately along a line, and then observe that the LS and LAV fits are quite similar. Now move a point or two (thereby simulating data recording errors or the occurrence of "outlier" points), and note that the LAV fit is usually less influenced than the LS fit by these changes in the data. Statisticians refer to LAV fits as being more "robust" than LS fits, although they can provide deeper mathematical insight into LS fits in general.
Note: Renewed interest in the LAV criterion in the past few years has led to diverse applications in, for example, medical imaging, seismic processing, and customer preference analysis and prediction. Unlike curve fitting problems, these new applications arise from underdetermined systems where the number of constraints or data points is less than the number of unknowns or fitting parameters.