Two example scripts are presented. The first program generates a 1D Gaussian from noisy data by two different strategies. First, using a semi-analytical method and secondly by using Matlab's "lsqcurvefit" function. Both results can be compared. The second program attempts to generate a 2D Gaussian from noisy data. This script is a re-formulation of the original idea by G. Nootz as the code is now more transparent and shorter.
Manuel A. Diaz (2021). Fit 1D and 2D gaussian to noisy data (https://www.mathworks.com/matlabcentral/fileexchange/55033-fit-1d-and-2d-gaussian-to-noisy-data), MATLAB Central File Exchange. Retrieved .
MATLAB Release Compatibility
Platform CompatibilityWindows macOS Linux
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!Start Hunting!