0
$\begingroup$

Hello I have a FTIR (fourier transform infrared) absorbance spectrum of a sample, Integrating the single lines is correlated to the quantity of substance present in the sample. The spectrum part I'm interested in is something like this:

spectrum

And I want to calculate the integral under a peak, in respect of the baseline, or something like this area:

integral

My idea was to get the baseline with a filter or something to cut the peaks and then integrate the curve with simpson method (and subtract the baseline integral on the same interval) or subtract the baseline to the curve and integrate then. Is there any way to get the baseline with packages like scipy or others? I'm new to spectrum analysis and I would be thankful for any suggestion!

$\endgroup$
4
  • $\begingroup$ Are you looking for an algorithmic approach to automatically detect the first or largest peak and do this over many cycles or you just need to do this a few times manually? $\endgroup$ Commented Mar 24, 2021 at 10:54
  • $\begingroup$ I can do it manually, I found an algorithm which is called "Asymmetric Least Squares Smoothing" by P. Eilers and H. Boelens in 2005. I'm testing it right now to see if I can find a way to fit a correct baseline. $\endgroup$ Commented Mar 24, 2021 at 10:56
  • $\begingroup$ Right, so just remove the samples where the peaks are and put that into your curve fit; it seems to me a linear fit between the local mean on each side of the group of two large peaks would be sufficient. Then Simpson’s rule just reduces to summing the sample differences (peak to base) to get a comparative area. $\endgroup$ Commented Mar 24, 2021 at 11:00
  • $\begingroup$ The photodetector is proportional to incident power not magnitude so a simple sum of the powers (in each sample along the horizontal axis) makes sense to get the total power under the curve, subtracting the background noise contributions. $\endgroup$ Commented Mar 24, 2021 at 11:02

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.