Normalize by ID

RucaRuca Member Posts: 13 Contributor II
edited November 2018 in Help
Hi all,

I would like to perform a Normalization into an example set.
My example set is the folowing:
ID att    weight
1  att1  12
1  att2    9
1  att3  10
2  att4  5
2  att5  9
2  att6  2

Which means that, for each ID I would like to perfom a Normalization to the weight column.
I've tried to use the "loop attributes" and selecting the single ID attribute operator with a normalize operator in its subprocess. My idea is to create a for cylce using the ID as the iterator.

Any hints on how to achieve this?
Any help is more than welcome.

Thanks a lot,



  • Options
    MariusHelfMariusHelf RapidMiner Certified Expert, Member Posts: 1,869 Unicorn
    Hi Ruca,

    to iterate nominal values you can use the Loop Values operator. Inside that you have to use Filter Examples with the attribute_value_condition to filter on the current id.

    If your Id is not nominal, you can apply Numerical to Polynominal on it.

    Happy Looping!
  • Options
    bert0077bert0077 Member Posts: 1 Contributor I

    I am looking to do a normalization also within an attribute and wonder if I need the same operators as Ruca.

    I have a list of product groups and prices. Since prices can vary between a few $/item and up to $1M/item, I need to normalize. Rather than normalizing by ID, I would normalize by product group such that all products of group 1 are normalized to each other, group 2 to each other, etc. so I can make meaningful comparisons of product groups with price. My data are like:


    ID group    price
    1  group1  1
    2  group2  10
    3  group3  1000
    4  group1  2
    5  group2  20
    6  group3  2000


    Group is a polynominal attribute; price is numerical. Of course I don't want to normalize all prices against each other so if I can use the looping operator to normalize each group at a time that would be awesome.



Sign In or Register to comment.