This site provides a java-based demonstration of how a least-squares analysis works. The applet opens with a set of data points with a superimposed line. By clicking and dragging, the user can move the data points and change the slope and/or the y-intercept of the line. The residual error for each data point is shown as a square whose area increases the greater the vertical distance between the point and the line. A total sum-of-squares also is shown. By adjusting the slope and y-intercept, the user can try to find the optimum line by minimizing the total sum-of-squares. By moving data points, users also can explore the effect of outliers. The site does not provide an explanation of the mathematical details of a least-squares analysis, nor does it explain the significance of the sum-of-squares. Nevertheless, instructors will find that this is a useful tool for illustrating a least-squares analysis.