Skip to main content
Solved

Aggregate attributes from other attributes


geo-x
Supporter
Forum|alt.badge.img+6

Dear FME community.

I try to aggregates lines to columns with same ID like that :

In fact it's an intermediate result what I want, because in final result, I need to have this same aggregation with comparaison of different values (best value is A than B) :

This is a link with a data test :

Tank you for your help.

Best answer by ebygomm

If you only want to keep the 'best' value you can assign a score to the value, sort by this score then use the duplicate filter or a sampler to keep only the ID with the 'best' score

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

5 replies

lars_de_vries
Forum|alt.badge.img+10

You could use the GroupBy function on the ID field and a Concatenate on the Value. The other option could be to use two Aggregators placed in serie. The first can group on both ID and Value and the second could just use ID.

Maybe you can use a TestFilter to define the best value, but I cannot Judge the comparison of the values.


ebygomm
Influencer
Forum|alt.badge.img+39
  • Influencer
  • Best Answer
  • April 12, 2019

If you only want to keep the 'best' value you can assign a score to the value, sort by this score then use the duplicate filter or a sampler to keep only the ID with the 'best' score


takashi
Evangelist
  • April 12, 2019

What is the definition of the "best value"? In other words, why is "A" is the best in "A", "B" and "Unknow"?


geo-x
Supporter
Forum|alt.badge.img+6
  • Author
  • Supporter
  • April 18, 2019
takashi wrote:

What is the definition of the "best value"? In other words, why is "A" is the best in "A", "B" and "Unknow"?

Dear @takashi in this case it is : B best than A, C best than B etc... it's a particular case


geo-x
Supporter
Forum|alt.badge.img+6
  • Author
  • Supporter
  • April 24, 2019
ebygomm wrote:

If you only want to keep the 'best' value you can assign a score to the value, sort by this score then use the duplicate filter or a sampler to keep only the ID with the 'best' score

Great answer @egomm, thank you very much !


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