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
Username:
Password:
Save Password
Forgot your Password? | Admin Options

 All Forums
 Origin Forum
 Origin Forum
 Get x for y from a spline
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic

emk

Finland
28 Posts

Posted - 12/15/2014 :  04:48:05 AM  Show Profile  Edit Topic  Reply with Quote  View user's IP address  Delete Topic
Origin 9.1.0 sr 4(Select Help-->About Origin):
Operating System: Win7

When using nonlinear fitting, you get an option for a worsheet that calculates x values for a column of y values, using the fitting function (this is obviously doen by itration as the inverse of the fitting function might not be available).
The typical application is generating the curve with a number of standards x(i) and their measurements y(i) and then using the cure fit function to find the values of unknowns x's based on their measurements (y)

Sometimes it is worth using splines instead of a fitting function, with splines the curve goes through all the standard points.

Is there as similar method for getting the unknown x's from measuremnts y using the spline?

lkb0221

China
497 Posts

Posted - 12/15/2014 :  4:12:28 PM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Hi,

You can first interpolate the curve by spline method first, and then use levelcrossing XF to find X by given Y.
http://www.originlab.com/doc/X-Function/ref/levelcrossing

Zheng
OriginLab
Go to Top of Page

emk

Finland
28 Posts

Posted - 12/16/2014 :  05:50:23 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Hi,
Thanks! This levelcrossing approach is to the right direction, but not fully what we are looking for:
In our application we have a number (say six) standards spread on the applicable x axis range. The standard curve may be quite nonlinear(e.g. sigmoidal) and it is not enough to linearly interpolate between adjacent standard points to get values for unknowns. Normally we use a nonlinear curve fit, and then it is very easy to use the the "find X for Y" option. However, sometimes there might be a problem with the fit and we would just like to smoothly (and not necessarily linearly) interpolate the standards with a spline curve, and similarly find X for Y. Typically there is quite a large number of unknowns, so the easiest would be a "find X for Y column" like the nonlinear fit.

I think there might be use in Origin for a general "read from the curve" tool that would allow getting the values from any curve plot, fit or even generated curve.

BR,
Eero
Go to Top of Page

cdrozdowski111

USA
247 Posts

Posted - 12/16/2014 :  06:57:41 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Eero,

There is a general read from the curve tool in Origin- the Vertical Cursor Gadget (http://www.originlab.com/doc/Origin-Help/Gadget-VerticalCursor). Granted it is manual, but you can output X/Y combinations to a report worksheet.

The uncheck the "Snap to nearest X" checkbox to get values between your actual data points.

Edited by - cdrozdowski111 on 12/16/2014 06:58:53 AM
Go to Top of Page

emk

Finland
28 Posts

Posted - 12/16/2014 :  09:14:04 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Hi,
The vertical cursor shows y for x, we need x for y - a horizonal cursor, but this should be automatic for a column of y values.
As this is a very common approach in all kind of analytics, I find it hard to beleive that this is not included in Origin (otherwise Origin seems to include everything I can image ever using )

The plot below might clarify the problem. We have 9 known standards at concentrations 1,2,3,...,9 and the spline curve connects their respective instrument reading values. For the unknowns, we have the readings (a y value column) and need the respective x values
via the standard curve (say, what is the concentration for a reading of 300). There must be a simple way of doing this.
_
Eero


Edited by - emk on 12/16/2014 09:16:23 AM
Go to Top of Page

snowli

USA
1398 Posts

Posted - 12/16/2014 :  09:38:51 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Hello,

Sorry, I will check if we can add a tool to fit your user story.

We do have an interpolate X or Y.ogw if you choose File: New: from Template: Interpolate X or Y.ogw.

But unfortunately it does linear interpolation. Maybe we should improve it so that it supports more interpolation methods.

Another workaround is after plotting graph, double click the plot to open Plot Details. Set Line connection to spline.

Then using Screen reading to read certain spline location's XY values.

Thanks, Snow

Edited by - snowli on 12/16/2014 09:39:25 AM
Go to Top of Page
  Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
The Origin Forum © 2020 Originlab Corporation Go To Top Of Page
Snitz Forums 2000