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
 Forum for Origin C
 interleave data

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
juannim Posted - 04/17/2007 : 3:45:27 PM
Origin Version (Select Help-->About Origin): 7.5
Operating System:xp
I need a labtalk script to interleave data from 2 columns. The first column looks like:
11949
3.0804
3490
0.6206
=
=
=
=

#1
5998
3.333
9520
0.7202
=
=
=
=

#2
6192
3.348
9423
0.7022
=
=
=
=

#3

I want to replace all of the cells containing = with the corresponding values in the adjacent colums. Help? Jonathan
1   L A T E S T    R E P L I E S    (Newest First)
zachary_origin Posted - 04/19/2007 : 8:34:47 PM
Not sure if this is what you want for the "corresponding"...
in your example data, col(1)[5]=col(2)[1], col(1)[6]=col(2)[2]... col(1)[ 8]=col(2)[4] ? Maybe I am wrong...

if it is, the script can be something like:


j=1;
for(i=1;i<wks.nrows;i++)
{
if (col(1)[i]== 0/0)
{
col(1)[i]=col(2)[j];
j++;
}
}




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