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
 Automated Plotting with scripts
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic

peter

0 Posts

Posted - 08/14/1998 :  12:19:00 PM  Show Profile  Edit Topic  Reply with Quote  View user's IP address  Delete Topic
Thanks to all who helped with the importing problems I was having. That's
working fine now.
I still did not get the plotting solved yet. I can program a script that let's
me plot all
columns into one graph (different layers) but I didn't get to program that for

every plot a different graph window is opened so I'll state my problem and
intentions again (and a little more elaborated).

I have a (huge) worksheet of 100 or more columns of about 70 rows. There is
one
X column on the left, all the others are Y columns. I want a script that goes
through the worksheet and makes SEPARATE graph window for every X-Y plot, using

a certain template. So I will end up with about 100 graph windows, I know.
I later want to be able to modify the data, so I cannot use 'open multiple
graphs'. I've tried several variations of this kind of script but they
would either not work or make origin crash.

Included script:
%A=cluster-mcs-mass.otp;
loop (var,3,data1!wks.ncols)
{
work -s var 0 var 0;
work -p line %A;
};

Thanks,

Peter

peter

0 Posts

Posted - 08/14/1998 :  12:33:00 PM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
... automated plotting once again

Hello,

the way I do plotting various columns in different graphs from one worksheet is like this:

wks.col1.type=4; #x-Column

loop ...
wks.col2.type=1; #y-Column
worksheet -s 0 0 0 0 : # select A L L !!!
worksheet - p mytemplate.otp
worksheet -b %E; # get the worksheet back as active window !!
wks.col2.type=2; # set column as none (or it will always be plotted)
loop end ...

if you do this with loops you have to replace col2 with col$(var) or something like that. or try work -t ..... The trick is simply to set back the column type before each plot command. Note that you cannot perform operations on the worksheet after plotting because the graph window is now the active one.

Hope this helps. At least for my applications it works like that Peter

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