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
 Columns long name in multiple rows

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
Clairekun Posted - 04/30/2019 : 06:17:58 AM
Origin Ver. and Service Release (Select Help-->About Origin): 9.2
Operating System: Windows 10

Hello,

I have little knowledge of Labtalk so please excuse me if what I'm asking is absurd.

I have txt files with multiple header lines. Column names are in different rows (one row per column name), as in:

L10 Mass (mg)
L11 Area (cm^2)
L12 Temperature (K)

I have not been able to find how to set column long name and units when the structure is like the one above. Is there any way to refer names and units to different lines, or do I have to type them manually using col(A)[L]$ = "Mass" and such?

There is another issue I would like to address (please tell me if I have to open a new topic for this); there is a variable embedded in the metadata I would like to extract to use in calculations. I have read about defining variables within the worksheet, but couldn't find how to do this programatically. What I would need is:

L1 Reference 0.205 mg

I would need to create a column with the formula Col(A)/0.205 (number varies depending on the experiment). I know how to create new columns; but I have read about adding variables via page.info and other methods, but I would have to do this every single time I imported a data file and I would rather define the string programatically (it is always at the same line and position) to save time.

1   L A T E S T    R E P L I E S    (Newest First)
yuki_wu Posted - 05/06/2019 : 05:04:35 AM
Hi,

I think you probably need to import the data into worksheet first, and then loop over the columns to set the long names by script.

You can take a look at this page to see how to loop over columns:
https://www.originlab.com/doc/LabTalk/guide/Looping-Over-objs

Regards,
Yuki

OriginLab

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