Skip to main content
Solved

How to create a new value whenever I come across a threshold in sorted data?


wrijs
Contributor
Forum|alt.badge.img+5
  • Contributor

Hello,

I have a dataset that looks similar to the image shown and I need to create the value in the attribute ROUTE shown in red. image.pngI need to create a new value for ROUTE whenever Duration>1 or Duration is Null. 

The data needs to be sorted firstly by Name, then by TimeStamp.

Then, whenever the previously mentioned condition of (Duration>1 or Duration is Null) is met, a new value needs to be created for ROUTE. 

How do I create a new value (with for example a new sequential number) whenever I come across (Duration>1 or Duration is Null) in my sorted data?

Best answer by geomancer

Use the Adjacent Feature Attributes option of the AttributeManager to have access to the attributes of the previous feature, and provide your logic as a Conditional Value.

Routenumber(Note: I added some extra logic where Name B begins. This may not be needed.)

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

2 replies

geomancer
Evangelist
Forum|alt.badge.img+51
  • Evangelist
  • Best Answer
  • June 7, 2023

Use the Adjacent Feature Attributes option of the AttributeManager to have access to the attributes of the previous feature, and provide your logic as a Conditional Value.

Routenumber(Note: I added some extra logic where Name B begins. This may not be needed.)


wrijs
Contributor
Forum|alt.badge.img+5
  • Author
  • Contributor
  • June 12, 2023
geomancer wrote:

Use the Adjacent Feature Attributes option of the AttributeManager to have access to the attributes of the previous feature, and provide your logic as a Conditional Value.

Routenumber(Note: I added some extra logic where Name B begins. This may not be needed.)

That did the trick, thank you


Reply


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