This program generates simulated experimental data from data files with exact data in order to perform sensitivity analysis as follows.
x, y(x), s ... one variable (usual) case x1, x2, y(x1,x2), s ... two variable case x1, x2, x3, y(x1,x2,x3), s ... three variable caseAfter reading in such files you can then use this program in several ways to perturb the y-values by adding random errors. Finally, an output file can be produced with old x-values, new y-values, and s-values set equal to, or approximately equal to, the standard error of y. The output file is then ready for curve fitting.
The input file must have exact values for y as a function of x and arbitrary s, e.g. s = 1. Such files can be generated by program MAKDAT, or editors MAKFIL(1 var.), or MAKMAT(2/3 var.), and they are not altered in any way by program ADDERR. The output files you save contain the simulated experimental data.
The statistical theory of experimental error assumes that
y-perturbed = y-exact + random errorand you have several choices for random errors.
Three commonly encountered models for s^2 (i.e. V(y) the variance of y) are given special prominence.
This program also allows you to generate pseudo random errors from a variety of distributions, so you can explore the effect of uniform, exponential, normal, or Cauchy random errors.
Weighted nonlinear least-squares regression analysis needs s to be the exact standard deviation of the y-value, but this can never be obtained in real life.
Three situations can occur.
Outliers are y-values with errors that are improbably large, or are not from the same distribution as the other errors. To avoid generating such errors in the previous options, the normal distribution is truncated at 3 standard deviations.
There are several ways you can add arbitrary errors to data to simulate outliers. You can use a Cauchy distribution, or add outliers directly to the original or perturbed data. The s-values can be left alone, or replaced by replicates re-calculated from the perturbed data set with outliers.
Positions and signs of outliers can be selected randomly or by the user, and the magnitude can be fixed in several ways. The outlier can be a fixed % of the exact |y|-value, it can be a set amount, or you can input individual errors etc.
Note that the effect of outliers can be very dramatic, especially when they occur at critical positions in small data sets.