Skip to main content
Solved

Grouping features in a table based on "*" or another symbol delamination

  • February 21, 2023
  • 2 replies
  • 21 views

hlynur
Supporter
Forum|alt.badge.img+10

Hello, couldn't really describe the problem in the Question field but to sum it up, I have a table of X/Y/Z that represent contours (see on photo)ContoursMeaning that between the "*" there is an independent contour, first one having 5 vertices, next one having 7 and so forth. Now I want to enter these vertices into a contour generator, but in the way that that Transformer creates separate contours from the "*" grouping, instead of a whole binge of criss-cross connected lines.

 

Probably best way to do this would to give each vertex group a common ID and then run contour generator with Group by "ID". But how on earth do I group based on the logic:

if X is within two * then it belong to the same group, then after the latter * there is a new group with a seperate ID and so forth?

 

-Please send help :D

Best answer by ebygomm

You can assign groups using adjacent attribute mapping

imagefeature[-1].X NOT_ATTRIBUTE_HAS_A_VALUE sets the value of Group to 0 if it's the first feature

If X equals *, the Group is incremented by 1, otherwise it stays the same value as the previous feature

This post is closed to further activity.
It may be an old question, an answered question, an implemented idea, or a notification-only post.
Please check post dates before relying on any information in a question or answer.
For follow-up or related questions, please post a new question or idea.
If there is a genuine update to be made, please contact us and request that the post is reopened.

2 replies

ebygomm
Influencer
Forum|alt.badge.img+44
  • Influencer
  • 3422 replies
  • Best Answer
  • February 21, 2023

You can assign groups using adjacent attribute mapping

imagefeature[-1].X NOT_ATTRIBUTE_HAS_A_VALUE sets the value of Group to 0 if it's the first feature

If X equals *, the Group is incremented by 1, otherwise it stays the same value as the previous feature


hlynur
Supporter
Forum|alt.badge.img+10
  • Author
  • Supporter
  • 35 replies
  • February 22, 2023

Great work on the help sending @ebygomm​, worked like a charm.

 

Thanks :D