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
 plot -an delay
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic

pavel1

Czech Republic
Posts

Posted - 06/02/2005 :  05:10:49 AM  Show Profile  Edit Topic  Reply with Quote  View user's IP address  Delete Topic
Origin Version (Select Help-->About Origin): 7.5SR5
Operating System: WinXP
Hello,
I use the "plot -an" command for real-time visualization of measured data. This commands puts data into a worksheet which is included in a graph layer content. It works fine for the first worksheet - points appear in the graph immediately. However, for all following worksheets added later to the layer, the points appear just after the next "plot" command - there is one point delay in displaying.
Of course, any kind of refresh helps but it replots all points which can take some time and can be a little bit disturbing.
The problem occurs when executing the "plot" command both from Script Window and from the VB client (by Execute Method).
Thanks.

greg

USA
1380 Posts

Posted - 06/06/2005 :  11:31:55 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Are you saying that a script such as this:

doc -s;
doc -n;
win -t data origin;
win -t plot doubley;
page.active=1;
x2=20;
layer -i data1_b;
page.active=2;
layer -i data2_b;
loop(ii,1,20) {
plot -an Data1 1 ii rnd()*10;
plot -an Data2 1 ii rnd()*5;
sec -p 1;
}

does not update the two plots at the same time?

(Note : the script is destructive, so save any work before running it.)

Go to Top of Page

pavel1

Czech Republic
Posts

Posted - 06/07/2005 :  06:07:30 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Hello Greg,
thank you for your answer. Double layer graph is not exactly what I have in mind. I have modified your script in the following way:

doc -s;
doc -n;
win -t plot LineSymb;
win -a Graph1;
x2=20;
layer -i data1_b;
loop(ii,1,10) {
plot -an Data1 1 ii rnd()*10;
type $(ii);
sec -p 2;
};
win -t data Origin;
win -a Graph1;
layer -i data2_b;
loop(ii,11,20) {
plot -an Data2 1 ii rnd()*5;
type $(ii);
sec -p 2;
}

Data from the sheet Data1 are displayed O. K. but the Data2 points appear in the graph delayed comparing to the worksheet and to the Script window. Moreover, the last point (ii=20) is not plotted at all unless the graph window is refreshed.

Pavel
Go to Top of Page

greg

USA
1380 Posts

Posted - 06/07/2005 :  10:07:32 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
We have verified the problem in 7.5SR5.

Your example doesn't quite illustrate the problem, which is that worksheets created after a graph lag in their real-time plotting. This also suggests a workaround for the problem - which may be needed since there may not be any more updates to 7.5.

This illustrates the problem:

doc -s;
doc -n;
win -t data Data2;
win -t plot line;
%M=%H;
win -t data Data3;
win -a %M;
layer -i data1_b;
layer -i data2_b;
layer -i data3_b;
loop(ii,1,10) {
plot -an Data1 1 ii 6.5+rnd()*3;
plot -an Data2 1 ii .5+rnd()*3;
plot -an Data3 1 ii 3.5+rnd()*3;
sec -p 1;
}

A re-arrangement of the above doesn't have the problem :

doc -s;
doc -n;
win -t data Data2;
win -t data Data3;
win -t plot line;
layer -i data1_b;
layer -i data2_b;
layer -i data3_b;
loop(ii,1,10) {
plot -an Data1 1 ii 6.5+rnd()*3;
plot -an Data2 1 ii .5+rnd()*3;
plot -an Data3 1 ii 3.5+rnd()*3;
sec -p 1;
}

The problem has been Trackered with ID 7786.

Go to Top of Page

pavel1

Czech Republic
Posts

Posted - 06/08/2005 :  08:28:24 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Thanks Greg,
I will use the workaround following your example - it works.
However, it would be nice to have one more Service Release solving the above problem.

Pavel
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