The Origin Forum
File Exchange
Try Origin for Free
The Origin Forum
Home | Profile | Register | Active Topics | Members | Search | FAQ | Send File to Tech support
 All Forums
 Origin Forum
 Origin Forum
 Generate Spline data

Note: You must be registered in order to post a reply.
To register, click here. Registration is FREE!

Screensize:
UserName:
Password:
Anti-Spam Code:
Format Mode:
Format: BoldItalicizedUnderlineStrikethrough Align LeftCenteredAlign Right Horizontal Rule Insert HyperlinkUpload FileInsert Image Insert CodeInsert QuoteInsert List
   
Message:

* HTML is OFF
* Forum Code is ON
Smilies
Smile [:)] Big Smile [:D] Cool [8D] Blush [:I]
Tongue [:P] Evil [):] Wink [;)] Clown [:o)]
Black Eye [B)] Eight Ball [8] Frown [:(] Shy [8)]
Shocked [:0] Angry [:(!] Dead [xx(] Sleepy [|)]
Kisses [:X] Approve [^] Disapprove [V] Question [?]

 
Check here to subscribe to this topic.
   

T O P I C    R E V I E W
a.abc.b35 Posted - 08/06/2014 : 2:52:21 PM
Origin Ver. and Service Release (Select Help-->About Origin): 8.5.1
Operating System: Windows 7

I am not sure how to achieve the following and your help in this regard will be much appreciated:

I want to subtract a spline baseline from a data-set. Let's say my original data is in two columns with long names: X-Original and Y-Original. Now I plot this data, and then using the Draw feature in Origin, draw a background data by clicking below the data points. Let's call the X, Y column of new draw-set as X-Draw and Y-Draw respectively. I would like to subtract the Draw data from the original data -- problem is the X-values are different!!!
I figured if I could access the internal parameters of the spline function for the Draw-data and then use the X-Original values for generating the Y-Background then I shall have background points at the same X as the original data and then i can subtract them easily.

Is there a way to do it in origin using the script window? say, having something like:

Y-Background=Use internal spline parameters on the spline data of Draw-data

Basically I want Y-background as the same spline function of the "X-draw vs. Y-draw" data but at X-positions of the "X-Original vs. Y-Original" dataset.

Can anyone please help me with that?
Thanks in advance.

AB
8   L A T E S T    R E P L I E S    (Newest First)
a.abc.b35 Posted - 08/07/2014 : 11:56:42 AM
Works like a charm..Thanks a lot to both of you.

AB
a.abc.b35 Posted - 08/06/2014 : 4:46:08 PM
Cool.. got it now.. that interpolate/extrapolate y from X helped...will let you knwo when i completely figure this out.

AB
lkb0221 Posted - 08/06/2014 : 4:19:19 PM
quote:
Originally posted by a.abc.b35

The x values for "Original" and "Draw" data are different!!!

AB



That's why we use the Interpolate/Extrapolate Y from X function, to get Ys on the same X.
lkb0221 Posted - 08/06/2014 : 4:15:22 PM
Hi,

Or, you can try using the Create Baseline method of Peak Analyzer, by manually pick the anchor points.

Or, mask the hump range of your original curve and then do a interpolation on it.

Anyway, there are multiple ways to do the similar thing. Not sure which one fits you best.

Zheng
OriginLab
a.abc.b35 Posted - 08/06/2014 : 4:12:12 PM
The x values for "Original" and "Draw" data are different!!!

AB
lkb0221 Posted - 08/06/2014 : 3:52:16 PM
Hi,

Then you just use Analysis: Mathematics: Interpolate/Extrapolate Y from X to get the points you want and replace the original ones by them.

Use data reader to read the points on the graph if you do not know the index range of that part.

Zheng
OriginLab
a.abc.b35 Posted - 08/06/2014 : 3:18:26 PM
I think I need to clarify -- I may have guided you in the wrong path. sorry about that.

I have a dataset with X-Original and Y-Original say. It's like an exponential decaying function but then it has got a hump in the middle. I do not want that hump (for whatever reason) and would love to replace that part with the smoothly varying function. But the data set is not exponential or any known function to begin with. So, I went to the method of "SPLINE". After plotting X-original vs. Y-Original, i DRAW a background function for the whole data range. The background is how the data should look like (say). My data is good for beginning and end part and only in the middle hump part, I would like to replace it with the SPLINE data.

Is that possible to do?

Below is a sample. i would like to get down the middle hump in Original data to the level of Draw background.



AB
lkb0221 Posted - 08/06/2014 : 3:07:48 PM
Hi,

1). Plot a spline line plot by original X&Y.
2). Select the plot, right click and choose Create Spline Data.
3). Use Analysis: Mathematics: Interpolate/Extrapolate Y from X to get the spline value at each original X position.
4). Subtract it from original Y.

No script window way, I'm afraid.

Zheng
OriginLab

The Origin Forum © 2020 Originlab Corporation Go To Top Of Page
Snitz Forums 2000