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
 remove plot from graph layer
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic

tschunck

Germany
13 Posts

Posted - 11/27/2024 :  4:50:24 PM  Show Profile  Edit Topic  Reply with Quote  View user's IP address  Delete Topic
Origin Ver.: 2015
Release: 10.2.0.188
Operating System: Win11

I am looking for a Labtalk-command to remove a data plot from a layer in a graph. I do have a graph layer with several line-plots in it. After addding a further plot for display during i am selcting something for my further calculations in the skript, I later want to remove this last added plot.

I managed to get the information about the number of plots in the layer using:
"layer -c;"
and than try to hide the last plot with:
"layer -hp 1 $(count);"

There are two problems :

1. Origin doesn´t update the assiciated graph-window information for the objects (="Objektverwaltung" in German). So the entrys are getting more and more confused after a while. This is seems to be abug of the new version.

2. I would really appreciate not to get to much plots in the graph and prefer to really delete the information that is not needed from the window and layer and file.

Is there any possibility to delete a known (e.g. by number) plot from the graph window. Of course I don´t want to delete the data from the corresponding worksheet.

Thanks in advance for any helpful comments

Peter

aplotnikov

Germany
165 Posts

Posted - 12/02/2024 :  3:50:39 PM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
https://www.originlab.com/doc/en/LabTalk/ref/Layer_Options_for_Plot#-e

To remove the n-th plot in the layer:
lay -c;
lay -e %[%Z, #<n>];
lay -ie; //remove the style holder if necessary



Edited by - aplotnikov on 12/02/2024 4:04:19 PM
Go to Top of Page

tschunck

Germany
13 Posts

Posted - 12/03/2024 :  10:34:55 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
quote:
Originally posted by aplotnikov

https://www.originlab.com/doc/en/LabTalk/ref/Layer_Options_for_Plot#-e

To remove the n-th plot in the layer:
lay -c;
lay -e %[%Z, #<n>];
lay -ie; //remove the style holder if necessary






Unfortnately this doesn´t work in my case!

The probelm is, that I plotted the same dataset several times (for example 15 datasets) in the same plot. The first dataset holds all my measured data from row1 to end. All other datasets hold just special "points of interest" (rows) form the same dataset and these points are plotted in different size an colour in order to highlite them in the graph window.As consequence %z holds 15 times the same dataset name.

When I perform the layer -e command using the 15th (=count) entry I do delete all plots from the graph instead of deleting the latest highlited selection.



Go to Top of Page

tschunck

Germany
13 Posts

Posted - 12/03/2024 :  10:49:49 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
https://my.originlab.com/ftp/forum_and_kbase/Images/Gra_PT.oggu
Go to Top of Page

aplotnikov

Germany
165 Posts

Posted - 12/03/2024 :  2:05:54 PM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Seems, that you have only two choices: either change your data in appropriate way - e.g., use additional columns to categorize your points, etc., or use OriginC instead of Labtalk. If I wrong I would be surprised, but I cannot except that.
Go to Top of Page

tschunck

Germany
13 Posts

Posted - 12/04/2024 :  07:29:36 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Thanks for thinking about it and I will search for other possibilities to solve this task.
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