I have a shapefile with many non-overlapping polygons, touching each other (see sample screenshot below):
All these polygons have a field called 'avg_ht' in the attribute table, which is a 32-bit float (average height of trees). Some of these polygons have to be merged with others based on the following criteria. Consider polygon1 and polygon2. They should be merged if:
- They are adjacent to each other
- abs(polygon1.avg_ht - polygon2.avg_ht) <= 1.0
Condition #2 above basically checks if the difference between the average heights of the candidate polygons is less than 1.0 units.
What is the best way to do this? I have license for the eliminate tool but am not sure if it is the best way.