Question

Fit and merge two sets of polygons

  • 4 November 2021
  • 5 replies
  • 51 views

Hi! I have two sets/layers of polygons, one containing boundaries for areas which my company have responsibility for, and one layer containing the categorization of the environment within these boundaries. The categorization layer should of course match the boundary layer exactly, but that is unfortunately not the case. Often, the categorization layer either overlaps the boundary, or there is a (very small) gap between the two. I have accomplished to remove the environment overlapping the boundary using the Clipper transformer.

 

What I want to do now is to fill in the gaps between the two layers, so that the categorization layer matches the boundary layer exactly. What I imagine I want to do is to fill in the gaps with the closest environment layer polygon, so that the polygon stretches out and snaps to the boundary. Any ideas on how to do this? I have tried to merge the two sets with each other, but since they do not have any common attributes that have failed.

 

Best regards!

 


5 replies

Badge +13

AreaOnAreaOverlayer is a very nice transformer to dissected the overlapped area out, it also allow you to merge the attribute when they touch as well. Another transformer you could try to filled the gap be AreaBuilder or may AnchoredSnapper. Hope this help!

AreaOnAreaOverlayer is a very nice transformer to dissected the overlapped area out, it also allow you to merge the attribute when they touch as well. Another transformer you could try to filled the gap be AreaBuilder or may AnchoredSnapper. Hope this help!

I had tried both AreaOnAreaOverlay and A.Snapper before w/o much success, but will try it again, I'm sure the problem was at me rather than the transformers. However, AreaBuilder made some progress, so thanks for that! I have now managed to combine the environment layer with the gaps so that they are in the same layer, just need to figure out a way to transfer attributes to the gap polygons because as of now thay are completely empty on attributes.

Badge +13

I had tried both AreaOnAreaOverlay and A.Snapper before w/o much success, but will try it again, I'm sure the problem was at me rather than the transformers. However, AreaBuilder made some progress, so thanks for that! I have now managed to combine the environment layer with the gaps so that they are in the same layer, just need to figure out a way to transfer attributes to the gap polygons because as of now thay are completely empty on attributes.

You could try Feature Merger or Feature Joiner and set it 1 and 1, this will force the attribute to merge. You can also put the connection on the rejection port, if it does fail, to see if they some of the features successfully merging. Feature that can't merge will go out to reject port without causing your workspace to fail. Hope this helps!

Userlevel 4
Badge +25

If you are halfway to a solution, then that's fine, but you could also try the AreaGapAndOverlapCleaner transformer. This transformer will fill in gaps in an overlay. It has the option whether to use the longest boundary as the fill area, or pick at random, or prioritize in other ways.

If you are halfway to a solution, then that's fine, but you could also try the AreaGapAndOverlapCleaner transformer. This transformer will fill in gaps in an overlay. It has the option whether to use the longest boundary as the fill area, or pick at random, or prioritize in other ways.

Amazing, this kind of solved it! I still have to tinker some with the settings, and some problems still remain because of errors in the input data, but this worked!

Reply