The first type of regression analysis was linear regression. The method of least squares was first published by Legendre in 1805 and in 1809 by Gauß. Both used the method to predict the movement of planets around the sun. Gauss published an improved method in 1821.