The Altair Community is migrating to a new platform to provide a better experience for you. The RapidMiner Community will merge with the Altair Community at the same time. In preparation for the migration, both communities are on read-only mode from July 15th - July 24th, 2024. Technical support via cases will continue to work as is. For any urgent requests from Students/Faculty members, please submit the form linked here.

convert from absolute value to percentage

kaymankayman Member Posts: 662 Unicorn
edited November 2018 in Help

Assume I have a recordset as this :


a1  a2  a3

1     1    2 

2     2    1 

1     2    1 


and I want to convert it from absolute value to percentage so my outcome becomes like this :


a1       a2        a3 

25%    25%    40%

50%    25%    40%

25%    50%    20%


Or in other words, for each of my attributes I want to get the sum by attribute, and then for each of the value the percentage.


I thought I would be able to do this with the loop attributes operator but I am not able to select the content so I'm doing something wrong somewhere.


What would be the easiest way to approach this? 

Best Answer

  • Options
    AndrewAndrew RapidMiner Certified Expert, RapidMiner Certified Master, Member Posts: 47 Guru
    Solution Accepted

    The Normalize operator has the useful option "proportion transformation" that rescales numeric attributes to be their fractional contribution out of 1. Use Generate Attributes to multiply this by 100 to get a percentage.




  • Options
    Telcontar120Telcontar120 Moderator, RapidMiner Certified Analyst, RapidMiner Certified Expert, Member Posts: 1,635 Unicorn

    The percentages in your example don't seem to line up properly, but based on your description, I think the fractional count function in the Aggregate operator does what you want. You just have to specify to group by your primary id variable, so it won't really be aggregating if you have no duplicates in your dataset.  But that's fine.  Note that if you want row percentages rather than column percentages you can do something similar with Generate Aggregation.

    Brian T.
    Lindon Ventures 
    Data Science Consulting from Certified RapidMiner Experts
Sign In or Register to comment.