ABSTRACT

In this chapter you learn how to use Python to perform linear and nonlinear least squares fitting of data to a function that is supposed to model the data. The methods employed allow for the weighting of the data according to uncertainties supplied by the user and uses χ 2 as the measure of the goodness of the fit .