How does matlab's gaussian fit function select peak centers

3 次查看(过去 30 天)
I have a series of data traces that represent change in two gaussian peaks over time. Each trace varies a little from the others due to noise but at least visually the two peaks are clearly visible at every time step. When I perform a "gauss2" fitting on the data occasionally it manages to successfully identify the two peaks and fit them well. Most time steps it seems to select the second peak far too close to the first peak and so instead of two clearly separated peaks it gives me a single big peak with a long tail. I think the problem is that it's failing to select the second peak center properly, so I was wondering how the "fit" program does that and how this might be resolved.
Thanks all

回答(2 个)

Kushagr Gupta
Kushagr Gupta 2017-6-8
Looking at the graphs, it seems that the kernel size being used is too large. In such a case, large amount of neighborhood data is being used to come up with the fit.
You would have to modify some of the parameters to get the desired result. As "gauss2" uses NonLinear LeastSquares method, I feel changing (reducing) the value of "DiffMaxChange" should give a better result. Lowering the "Span" field value can also help in getting the second peak but it depends on what fit type is being used.
I would recommend playing around with the different algorithms available and tweaking their settings to get a desired result.

Gaurav
Gaurav 2017-12-6
James,
Could you solve the problem and share the solution?

类别

Help CenterFile Exchange 中查找有关 Mathematics 的更多信息

产品

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by