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 for Programming
 LabTalk Forum
 Get X column from graph
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic

L007

12 Posts

Posted - 05/26/2009 :  4:49:41 PM  Show Profile  Edit Topic  Reply with Quote  View user's IP address  Delete Topic
Origin Ver. and Service Release (Select Help-->About Origin): 7.5 SR4
Operating System: XP

Hi, maybe this is an easy question.

In a labtalk script, one can use xof(%A) to find the X of dataset %A. This works fine when one wants to find the X value of %A in a script IF the plot is created using Origin´s standards (i.e. plot Y1 against X1, Y2 against X2, etc.).
However, in many cases it is not possible, since if for example one wants to plot Y2 against Y1 (using the Plot Setup window, for example). In this case the graph and dataset won´t match (still it is not advantageous to change the column definitions, because you still have (X1,Y1) and (X2,Y2) plots).
For this particular case, xof(%A), where %A is (Y1,Y2), will return X1 and not Y1. How to proceed in this case?

greg

USA
1379 Posts

Posted - 06/10/2009 :  3:23:45 PM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
With the plot active, XOF function will get the X used by the specified Y, so
%A = xof(%(N,@D));
will set the %A variable to the X dataset used by the Nth dataplot.
e.g.
%A = xof(%(2,@D));
gets the x dataset used by the second dataplot in the active layer of the active graph window.
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