Skip to main content
Solved

Absolute Max Value of list

  • November 22, 2017
  • 3 replies
  • 245 views

Forum|alt.badge.img

Hi All,

How do i find the abs MAX value of a list.? (ie MAX(ABS(list[-4,-2,1,3))) would return 4

Thanks

Best answer by erik_jan

Using the ExpressionEvaluator transformer:

Results in the value 4.

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.

3 replies

erik_jan
Contributor
Forum|alt.badge.img+23
  • Contributor
  • Best Answer
  • November 22, 2017

Using the ExpressionEvaluator transformer:

Results in the value 4.


Forum|alt.badge.img
  • Author
  • November 22, 2017

Using the ExpressionEvaluator transformer:

Results in the value 4.

I get it now!

 

get the max and min using the range extractor then get the max of the max and abs(min)

 

 

Thanks Again

 

 

Steve

 

 


erik_jan
Contributor
Forum|alt.badge.img+23
  • Contributor
  • November 22, 2017

Using a list this is the better way:

Sort the list and use the first (0) and last (_element_count) to do the calculation.