The Altair Community is migrating to a new platform to provide a better experience for you. In preparation for the migration, the Altair Community is on read-only mode from October 28 - November 6, 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
Calculation by Groups
Hi,
This is a newbie's question...I have a data which looks like the below:
Group Value
1 78
1 64
1 75
2 66
2 54
2 72
2 77
3 57
3 59
3 61
Now, i want to do a calculation by groups. And this calculation is ABS("Value" - Group Average). The output datafile should look like the below:
Group Value Result
1 78 5.666666667
1 64 8.333333333
1 75 2.666666667
2 66 1.25
2 54 13.25
2 72 4.75
2 77 9.75
3 57 2
3 59 0
3 61 2
This is exactly group processing. How do we do this in Rapid Miner?
Many thanks for your help,
Shubha
This is a newbie's question...I have a data which looks like the below:
Group Value
1 78
1 64
1 75
2 66
2 54
2 72
2 77
3 57
3 59
3 61
Now, i want to do a calculation by groups. And this calculation is ABS("Value" - Group Average). The output datafile should look like the below:
Group Value Result
1 78 5.666666667
1 64 8.333333333
1 75 2.666666667
2 66 1.25
2 54 13.25
2 72 4.75
2 77 9.75
3 57 2
3 59 0
3 61 2
This is exactly group processing. How do we do this in Rapid Miner?
Many thanks for your help,
Shubha
0
Answers
BR, Shubha
it's actually pretty simple:
Please note that the first chain is only used for generating data like you have described. The ValueIterator together with the aggregation and the merge do the trick.
All the best,
Ingo
A question is:
Can I do this without splitting the data into 3 data parts( according to the groups)...
with a different (and more complex) setup for RM 4.4 (coming this week): yes, it would also be possible without "dividing" the data. But what's wrong with it? Actually, the different data parts are only views on the same data set and therefore should be no problem at all.
Cheers,
Ingo
Thanks,
Shubha
One last question,
While I join daasets in the end by "ExampleSetMerge", the group order is changed. How to get back the original group order while merging? Is there a way to reverse the order number of the 3 different datasets generated?
Thanks,
Shubha
Cheers,
Ingo
We have the generated split datasets. While joining itself, can we join in the order? Or atleast in the descending order? This would help another problem of mine...
Thanks, Shubha