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 for Programming
 LabTalk Forum
 addding comments to 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
andrewdsto Posted - 05/09/2012 : 04:32:56 AM
Origin Ver. 8.5 and Service Release 1(Select Help-->About Origin):
Operating System: windows XP

Hi,
I have a data plot(s) containing some dataset ... for example

%c=;
filtered_U2@2

this tells me the dataset is contained within the worksheet called filtered on the second sheet and in a column headed U2.

All very well
however I wish to add a comment to the column's comment field eg "data is filtered"

Is there a simple way to do this using the fact that the dataset is contained within %C and this points to an actual dataset located within a worksheet.

Of course I can strip out all the relevant information and create code to determine the sheet name and relevant column number from the dataset name.. which leads to something like the following code

[filtered]e1u1!col(3)[c]$= "data is filtered";


but I thought there might be a simple way of adding the comment to the column, simply by knowing %c = filtered_U2@2.

I mean
filtered_U2@2[c]$= "data is filtered";

for example.. does work
but how do I enter the correct substitution using only %c to make it work?


Also.

I can also use a string variable so that activefilterset$=%c;
such that
activefilterset$=;
returns
filtered_U2@2

this is in fact my preferred way of dealing with datasets so that I don't loose or confuse which dataset I am manipulating.


thanks
Andrew




6   L A T E S T    R E P L I E S    (Newest First)
Sam Fang Posted - 05/10/2012 : 04:27:18 AM
Yes. %(afset$)[c]$ can't work in 8.5.

It is a bug in Origin8.5. It has been fixed in 8.6.

Sam
OriginLab Technical Services
andrewdsto Posted - 05/09/2012 : 11:45:23 PM
point taken with the spelling, but the problem still exists


afset$=%c;
%c=;
afset$=;


%c[c]$ = "filter attempt 1";
type ok;
%z=afset$;
%(afset$)[c]$ = "filter attempt 2";
type ok 2;
%z[c]$ = "filter attempt 3";
type ok3;



filtered_U2@2
filtered_U2@2
ok
#Command Error!
Sam Fang Posted - 05/09/2012 : 10:27:01 PM
There is a spelling error in your script. It should be activefilterset$ not acitivefilterset$.

Sam
OriginLab Technical Services
andrewdsto Posted - 05/09/2012 : 10:00:00 PM
actually, here we go, the error occurs with the use of the assigned dataset variable name:- activefilterset$


acitivefilterset$=%c;
%c=;
acitivefilterset$=;

%c[c]$ = "filter attemp 1";
type ok;
%(activefilterset$)[c]$ = "filter attemp 2";


filtered_U2@2
filtered_U2@2
ok
#Command Error!



ok so I can get around this by a temp assignment to %z for example


acitivefilterset$=%c;
%c=;
acitivefilterset$=;

%c[c]$ = "filter attemp 1";
type ok;
%z=activefilterset$;
%z[c]$ = "filter attemp 2";
type ok2;


filtered_U2@2
filtered_U2@2
ok
ok2



but why doesn't the actual assignment work?
andrewdsto Posted - 05/09/2012 : 9:42:34 PM
thanks Sam,

You know I tried that before I posted the question and it failed, but now it works... the reason I posted the question is because I thought it should work.
Maybe just a temporary bug, it was running a little slow. Perhaps next time I will exit and come back in a try when it is a simple thing.

thanks Again.

Sam Fang Posted - 05/09/2012 : 04:56:19 AM
You can use:
%C[c]$= "data is filtered";


or

%(activefilterset$)[c]$= "data is filtered";


Sam
OriginLab Technical Services

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