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
 Three data columns

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
hetanquary Posted - 02/04/2011 : 4:49:17 PM
Origin 8.1 SR1 v8.1.13.88 (Academic)
Operating System: Windows XP

I have a program which generates an ascii file consisting of 3 columns of data (say A, B, and C). I have two graphs which I would like to make from it: A vs. B and A vs. C. I have made two separate templates for this purpose. When I open one template and then import my data it by default plots both A vs. B and A vs. C on the same graph. I realize this can most likely be fixed easily using the import wizard, so I have spent some time attempting to figure out how to do this but have not yet been able to. Help would be appreciated.

5   L A T E S T    R E P L I E S    (Newest First)
hetanquary Posted - 02/10/2011 : 7:45:15 PM
Thank you very much! You have been very helpful!
easwar Posted - 02/08/2011 : 2:20:13 PM
quote:
Originally posted by hetanquary

Thank you very much! It worked great. I would like to learn more about scripting though. One thing I'd like to do that you might know how to do is I'd like to specify the type of graph that will be plotted. For instance, at the moment I guess it's plotting the data in a default plot type but I would like to have it be a line plot. Specifically, how does one script that? And then generally, what resources are available to learn commands in origin? I am relatively familiar with java and fortran, so is there just a list of commands that I could refer to that you know of?



Hi,

You can refer to the LabTalk help file in your Origin installation.

The latest content is on our wiki:
http://wiki.originlab.com/~originla/wiki/index.php?title=Origin_Programming
Select the 2nd link and that will take you to online LabTalk scripting guide, language reference, and examples. The content here is based on our latest version 8.5.

For example, to make a graph with a particular style, you can refer to the plotxy x-function, which is covered in this section of the guide:
http://wiki.originlab.com/~originla/ltwiki/index.php?title=Script:Creating_Graphs

Easwar
OriginLab

k.anderson3454 Posted - 02/07/2011 : 8:26:22 PM
Glad I came across this. Thanks

hetanquary Posted - 02/07/2011 : 3:56:51 PM
Thank you very much! It worked great. I would like to learn more about scripting though. One thing I'd like to do that you might know how to do is I'd like to specify the type of graph that will be plotted. For instance, at the moment I guess it's plotting the data in a default plot type but I would like to have it be a line plot. Specifically, how does one script that? And then generally, what resources are available to learn commands in origin? I am relatively familiar with java and fortran, so is there just a list of commands that I could refer to that you know of?
easwar Posted - 02/07/2011 : 12:14:05 PM
Hi,

You could do the following:
1> Use Import Wizard to create a new import filter, which imports the data into a workbook instead of a graph
2> On the Save Filters of the wizard, check the Save Filter check box, then give a name to your filter etc, and also check the "Specify advanced filter options" check box
3> On the page that opens next, add these script lines:

// Define ranges to point to cols 1, 2, 3 of worksheet
range r1=1, r2=2, r3=3;
// Plot col 2 versus 1 using template 1
plotxy iy:=(r1,r2) ogl:=[<new template:="My Template 1">];
// Plot col 3 versus 1 using template 2
plotxy iy:=(r1,r3) ogl:=[<new template:="My Template 2">];


Replace "My Template 1" etc with the name of your custom template. This will then create two graphs after the data has been imported into worksheet.

Easwar
OriginLab

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