0

After several manipulation of some data I find my self with an array of values which I want to approximate with a sum of Gaussian curves.

As you can see in the picture I have a curve (red) and I'd like to find a given number of Gaussian that approximates that curve in order to describe it in another system: e.g.1I want to find the four green gaussian described by mean and variance parameters (something like N(m,s)). The red curve is described by an array of 25 values.

===EDIT=== Here I post all the curves I need to descrbe, with noise removed, in order to give more info about the kind of data we are talking about: Intensity Curve. these are 11 float array of variable lenght.

L.Vezzani
  • 55
  • 5
  • Maybe this answer helps: https://stackoverflow.com/a/35992526/8664416 – addem Mar 14 '21 at 18:30
  • You may also look [here](https://stackoverflow.com/a/61725255/803359) This is for an unknown amount of Lorentians. Should be easy to modify it for a known amount of Gaussians. – mikuszefski Mar 15 '21 at 07:00
  • We can help you out better if you both upload what you have tried so far and a sample of your data. ps. IMHO if the data you want to fit are the ones in the image you posted I'm really skeptical you can use a sum of gaussians as a fitting function. Even if the physics underneath is well described by 4 gaussians, there seems to be way to much overlap between them to achieve a good fit. – Andrea Mar 15 '21 at 07:38
  • I tried several method include the one suggested, but none of them works ( especially the manual ones). @Andrea yes the datas are all like those seen in the picture and there are several of those. – L.Vezzani Mar 15 '21 at 08:36

0 Answers0