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
 data of the selected part of a curve
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic

sanguo

USA
Posts

Posted - 03/27/2006 :  6:12:16 PM  Show Profile  Edit Topic  Reply with Quote  View user's IP address  Delete Topic
Origin Version (Select Help-->About Origin): 6.1
Operating System:xp
Hi:
I am programming with labtalk, my question is if i have a curve, i select part of the curve with data selector button, which command i should use in the script to put the data of the selected part of the curve into a new worksheet ( say data2) thanks

Mike Buess

USA
3037 Posts

Posted - 03/28/2006 :  08:17:49 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Mks1 and mks2 are the indices of the two data markers so run this after you've used the data selector...

i1=mks1; // index of first marker
i2=mks2-i1+1; // number of points selected
%B=%C; // name of active Y dataset
%A=xof(%C); // name of corresponding X dataset
win -t D; // create new wks
set %H -er i2; // make sure it has enought rows
copy -b i1 %A col(A) -b 1 -e i2; // copy X data
copy -b i1 %B col(B) -b 1 -e i2; // copy Y data

Mike Buess
Origin WebRing Member
Go to Top of Page

sanguo

USA
Posts

Posted - 03/28/2006 :  11:36:44 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply

Thanks a lot, it is fabulous
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