Inteactive Curve Fitting/Model Interaction:

The most general way of fitting any model to a set of data is the iterative method, a kind of "trial and error" procedure in which the parameters of the model are adjusted in a systematic fashion until the equation fits the data as close as required. This sounds like a brute-force approach, and it is. In fact, in the days before computers, this method was only grudgingly applied. But its great generality, coupled with advances in computer speed and algorithm efficiency, means that iterative methods are more widely used now than ever before.

Guess, Check and Chug can now be very rapid and should be exploited.

Iterative methods proceed in the following general way:

  1. you select a model for the data - the exercise this week has this component (7a)

  2. you make first guesses of all the non-linear parameters and their qualitative behavior with respect to the data when they are tweakd

  3. a computer program computes the model and compares it to the data set, calculating a fitting error - usually chi2

  4. if the fitting error is greater that the required fitting accuracy, the program systematically changes one or more of the parameters and loops back around to step 3.



For the computer scientist, the main difficulty of the interactive methods is that they sometime fail to converge at an optimum solution in difficult cases.

Often times, procedures get trapped in "local minimums" (this is the stock market problem) and fail to escape to find the global minimum in a sea of local minima (with noise).

In most physical systems real data noise matters and intrinsic noise represents your computational limits and not your algorithm. This seems very hard for computer scientists to sometimes understand or appreciate.

The reliability of iterative fitting, like classical least-squares fitting, depends strongly on a good model, the signal-to-noise ratio, and the number of data points. It is not practical to predict the standard deviations of the measured model parameters using the algebraic approach, but both the Monte Carlo simulation and bootstrap methods are applicable.

Two example interactive interfaces: