Author |
Topic  |
|
penaglly
Canada
2 Posts |
Posted - 02/02/2011 : 6:39:29 PM
|
Origin Ver. and Service Release (Select Help-->About Origin): 7
Operating System: win xp
I want to subtract a spectrum baseline that has been recorded with fewer X points than the spectrum: 2 sets of data
X1S=700.00 Y1S=y11 X1B=700.00 Y1B=yb1 X2S=699.00 Y2S=y22 X3S=698.00 Y3S=y333 X2B=698.00 Y2B=yb2
and so on - the data needs more points due to fine structure - the baseline is essentially flat.
So it would be ok to calculate:
at X1S Y1corrected=Y1S-yb1 at X2S Y2corrected=Y2S-yb1 then go to yb2 etc
How can this be done easily in Origin 7? I have data sets of 1000 points or less.
|
|
greg
USA
1379 Posts |
Posted - 02/03/2011 : 09:39:36 AM
|
Your notation is not clear, but if you have a worksheet with X,Y plot designations that is your spectrum and a worksheet with X,Y plot designations that is your baseline Then you can plot your spectrum and use Analysis : Simple Math and subtract the baseline data.
From a plot of just the spectrum, Origin will automatically assign the 'Y1' data. Type '-' in the operator box and select the baseline Y dataset to use as 'Y2'. Click OK and Origin handles the interpolation seemlessly.
WARNING: The spectrum data is altered by the subtraction, so if you need to keep the original data as well, duplicate the spectrum worksheet before subtracting. |
 |
|
penaglly
Canada
2 Posts |
Posted - 02/03/2011 : 09:53:15 AM
|
I tried to make it clear that the X's did not match. So the simple math wouldn't work. I clearly didn't make it clear.
So for a reasonably flat baseline one doesn't need so many data points. Sophisticated programme will interpolate, but we don't need to because the X difference is very small. But I need a way of using the same baseline Y twice for successive data points. So, simple subtraction isn't the answer I think. And, yes, we can live with the data file being adjusted.
May be this is clearer:
X1S X2S X2S X3S Y1S Y2S Y2S Y3S
Y1B --- Y2B ---
Y1C Y1C Y1C Y1C corrected sample data
How to reuse Y1B for Y2S easily for 1000 points?
Thanks,
|
 |
|
greg
USA
1379 Posts |
Posted - 02/07/2011 : 1:22:01 PM
|
I understood that the X values do not match and I thought I had made it clear that it does not matter and that it would simply work.
As long as the datasets in question have proper X,Y Plot designations, then the subtraction is handled seemlessly by Origin.
The baseline dataset is not affected by the subraction, so it can be subtracted from any number of datasets.
It's all seemless because Origin uses the X values in the baseline dataset to determine where the subtractions occur. Origin uses interpolation to accomplish this. Perhaps you thought interpolation was not needed since the reduced X values (700, 698, 696, etc.) are all found in the raw data X (700, 699, 698, 697, 696, etc.).
In this case, interpolation is not needed, but Origin is written to handle even more complicated situations. Here it is internally used, but no interpolated values are needed since a real value is found at every X. |
 |
|
martinol
Canada
1 Posts |
Posted - 02/07/2011 : 6:13:38 PM
|
Thank you! Worked perfectly.
It was understanding and trustung that the math-engine knew to interpolate - I couldn't find that easily in Help. |
 |
|
|
Topic  |
|
|
|