cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
  • Don’t miss your chance to experience Discovery Summit Europe at our best available rate! Early bird registration through 31 Oct.
  • Image to Table JMP extension imports single or batch images as data tables. Useful to extract curves from pictures or convert image data to curve data to use in analyses like Functional Data Explorer. Download and install the extension.

Discussions

Solve problems, and share tips and tricks with other JMP users.
Choose Language Hide Translation Bar
Jackie_
Level VII

Loop through the list and concate

Hello forks,

 

I am trying to loop through the list and contact the string but it only reads the first value in the list.

Is there a workaround?

 

 

Jackie__0-1686339753960.png

 

Here's the code:

dt = current data table(); 
//List 1
uniq = {"S", "V"};
//list 2 binnaming = {"Dummy", "Sigma"};
Loop through the list to concede the strings and write to the data table rows For( i = 1, i <= N Items( uniq ), i++, :Column 1[i] = "BIN = \!"" || Substr( Char( uniq( i ) ), 3, 1 ) || "\!" " || " \!"" || Substr( Char( binnaming( i ) ), 3, Length( binnaming( i ) ) - 3 ); );


 

1 ACCEPTED SOLUTION

Accepted Solutions
jthi
Super User

Re: Loop through the list and concate

You are using wrong way of accessing the values in a list while using indices. Try changing () to [], for example uniq(i) -> uniq[i]

-Jarmo

View solution in original post

1 REPLY 1
jthi
Super User

Re: Loop through the list and concate

You are using wrong way of accessing the values in a list while using indices. Try changing () to [], for example uniq(i) -> uniq[i]

-Jarmo

Recommended Articles