Skip to main content
Solved

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

  • February 21, 2023
  • 2 replies
  • 12 views

hlynur
Contributor
Forum|alt.badge.img+7

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

View original
Did this help you find an answer to your question?

2 replies

ebygomm
Influencer
Forum|alt.badge.img+39
  • Influencer
  • 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
Contributor
Forum|alt.badge.img+7
  • Author
  • Contributor
  • February 22, 2023

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

 

Thanks :D


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings