Fitting gaussians with unknow no of peaks

[size=150]I found the answer here: $ROOTSYS/tutorials/spectrum/peaks.C
Please disregard this post. How do I delete a post?[/size]

Hello All,

I have some data that has several well defined peaks. I do not know in advance the no of peaks. How do I fit a gaussian to measure the FWHM of each peak individually.

Data file attached with the file. 

In the image below, there are 7 peaks (and I do not know that in advance) and I would like to extract the FWHM of each of the seven peaks.

Many thanks,
OD_S141_horiz.txt (4.34 KB)

You can use the class TSpectrum. see example in $ROOTSYS/tutorials/spectrum/peaks.C


Hello Rene,
I have the same problem that is i wish to find the FWHM of each peak in multipeak histogram
I have gone throud peaks.C macro. That works perfectly fine, finding the number of peaks
and doing nice fitting also, but how to find FWHM of individual peaks.

If i have only one peak in my histogram then i am able to find FWHM.
But in the case of multiple peak in same histogram i am not able to do.

Please suggest how to do this.

Thanks and with Regards,