An example of using least squares to do data fitting. In this example, we demonstrate how to 1) fit a straight line using ordinary least-squares method, and 2) estimate value of a new input based on the fitted line.