Custom Fit Function using Predefined waves
Thu, 11/08/2018 - 08:51 am
So to preface my question, I have many spectra that are made up of mixtures of two different species with overlapping features. I have the spectra of each individual specie that I can sum together to recreate the mixture spectra if I apply the right mixture coefficients. Instead of doing this manually to find the mixture ratios, I wanted to write a fit function in Igor to fit each spectra and use the coefficients to find the ratio.
I tried to use the custom fit function to write my own fit, but I find I can't seem to use the spectra waves of the two species in the fit function without error.
Example: f() = a*Sp1+b*Sp2
a=coeff of Sp1
b=coeff of Sp2
Sp1 = reference wave of species 1
Sp2 = reference wave of species 2
How could I go about remedying this?