jenk660

Iteration in Model Builder

Discussion created by jenk660 on Nov 15, 2013
Latest reply on Nov 20, 2013 by jenk660
Hi All

I have been trying to create a feature iteration in model builder. I will quickly explain what I am trying to achieve and then how I have built my model. Any help on how to get the iteration to work would be appreciated.

So I have a spatial map with a point feature shape file (imagine a random spread of points across the UK) overlaid by a fishnet (2kmx2km grid). Each grid cell is an independent polygon and is assigned a unique identifier in the attribute table). What I am trying to do is take each polygon in turn, select the points within that cell and then run a nearest neighbour assessment. My end product would be a nearest neighbour ratio result for each polygon.

In model builder I have been able to create a model that works when I select an individual polygon but not when I try and add an iterator tool. So the model currently starts with a feature iteration of the polygon shape file, the output feature is used as an input into a select by location along with the point shape file (designed to select the points within each polygon progressively) and then this output is used to run the nearest neighbour tool. The nearest neighbour report being the final goal.

So as i mentioned the model runs for a selected polygon but no longer works when i try to automate the process and 'iterate'. If anyone has any thoughts and/or advice it would be greatly appreciated. Also if anyone has an idea how I create a process for pulling out and aggregating the NN results that would also be of great (obviously not opening each result and copy it out individually...)

Thanks

Chris

Outcomes