cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
JMP is taking Discovery online, April 16 and 18. Register today and join us for interactive sessions featuring popular presentation topics, networking, and discussions with the experts.
Choose Language Hide Translation Bar
vishwasanj
Level V

data filter for loop

Hi,

I am fairly new to scripting. I understand for loop but I need a little bit of help here.

I am not able to find the for loop example for a data filter in the scripting guide. If someone could help me with the syntax, that would be great.

 

What I am trying to do is, I have a treemap and I need to construct a 'for' loop with the data filter table to get the graph outputs saved as .png file automatically.

 

I have attached a figure. For example, condition 1: wafer 11, choosing all Vpp trimset for 25C and Formula NO (1 graph)

                                                               condition 2: wafer 12, choosing all Vpp trimset for for 85C (0,11111)and  and Formula NO (1 graph)

                                                               condition 3: plotting each trimset value for all for wafer 11( 9 graphs) and wafer 12 with YES (2 graphs)

I am able to do it if I do it one by one in a code, but not together.

 

Thank you

13 REPLIES 13
vishwasanj
Level V

Re: data filter for loop

I understand what's going on. Thank you for the really good explanation Craige.

 

I believe if the condition doesn't find any rows associated with the condition, it breaks and stops.

"This Where-clause for data table 'Final table' resulted in no rows: Wafer == "12" & Formula == Empty()"

Instead, can it proceed so that it can keep plotting with the loop?

 

 

David_Burnham
Super User (Alumni)

Re: data filter for loop

The example I give below contains code that will skip combinations for which there are no rows

 

http://www.pega-analytics.co.uk/blog/scripting-data-filters/

 

 

-Dave
Craige_Hales
Super User

Re: data filter for loop

Nice!
Craige
vishwasanj
Level V

Re: data filter for loop

Thank you @David_Burnham, @Craige_HalesCraige and @txnelson

 

You guys rock!