Skip to main content
Archived

Add a ListExpressionEvaluator

Related products:Transformers
  • May 23, 2016
  • 1 reply
  • 33 views

Forum|alt.badge.img+5

To provide more functionality on working with lists I would like to propose a ListExpressionEvaluator transformer. This would evaluate a specific expression on every item in a list. The result can overwrite a list item or form a new attribute on the list.
In the expression you would have access to the attributes of a list item, and all the attributes of the feature itself. As an example list:

someList[0].Value1 = 15 someList[0].Value2 = 30 someList[1].Value1 = 15 someList[1].Value2 = 20

The user would pick the list: somelist. The expression could be: MaxValue = max(Value1, Value2).

Which would leave the list as:

someList[0].Value1 = 30 someList[0].Value2 = 15 someList[0].MaxValue = 30 someList[1].Value1 = 15 someList[1].Value2 = 20 someList[1].MaxValue = 20

Bonus points for providing access to previous/subsequent list items, similar to the adjacent feature access on the AttributeCreator. This can of course be accomplished with Python or a ListExploder, but preferably we won't need Python and I can keep my features intact.

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.

1 reply

jdh
Contributor
Forum|alt.badge.img+40
  • Contributor
  • June 13, 2016

For me it is often a conversion. ie convert every value in this list from feet to meters (*0.3048), and ideally would have the option to replace values rather than create a new list.