Iterate a table partition in a nested loop


I'm quite beginner at Knime, I'm trying to make a workflow where basically I have to iterate two tables ( one row by row, and another in a group of 10 by 10 ) in each iteration of the first table I have to iterate all the second table making two partitions, the first with ten rows and the second with the remaining rows ( a kind of cross-validation but using a node that I developed).  The inner loop will be completed when all sequential group of partition (training and test) have been tested.

The problem is that I'm not figuring out how to make the both loops work properly. I have tried several nodes to loop and partitioning including X-Partitioner but without success. Can anyone give me some tips ?

Follow my current workflow

First attempt:
Second attempt:



first, you can consider a Loop Start and  a Loop End as brackets. Hence, the number of loop starts and loop ends have to be the same. In your first, there is a loop end missing, in the second attempt two.

Than, if this message comes (Can't merge flow variables! Likely a Loop Problem) you need to make a deterministic order of the loop. If you take a look at your first attempt. For the order it doesn't matter if first the top Counting loop or the lower counting loop is executed.

To correct this connect one with the second one via Flow Variables. Than the loop has a determinstic order and know how to merge the variables.

Cheers, Iris