Advent of Code is back! Unwrap daily challenges to sharpen your Alteryx skills and earn badges along the way! Learn more now.
Free Trial

Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.

Multi Field Binning with Equal Sum?

DHodges
5 - Atom

I am trying to group my data into 4 groups with the optimal equal sums by the number of records divided by the 4 groups. In the example data below I have 11 records, so I would want three groups of 3 and one group of 2 binned by the closest equal sum among them. The "Group" column in the table was my quick guess on the desired output, however most likely there will be a more optimal solution! The number of records may change, so this would need to be dynamic. I played around with the Tile tool which gives the closest result, however I could not limit to the desired 3 3 2 groupings. 

 

Any help would be much appreciated!

 

 

Data FieldValuePercent Total# Per Group (Count Data Field/4 Groups)Group
Data Point 12524%2.75A
Data Point 22221%2.75B
Data Point 313.0012%2.75C
Data Point 41211%2.75D
Data Point 51110%2.75D
Data Point 66.006%2.75C
Data Point 74.004%2.75C
Data Point 84.004%2.75B
Data Point 94.004%2.75B
Data Point 1022%2.75D
Data Point 1122%2.75A

 

 

 

Thank you!

 

 

 

4 REPLIES 4
Shifty
12 - Quasar

Hey @DHodges - you might have already solved this but I hate seeing a question go unanswered so here's my shot:

Would the Tile tool do a job for you?

Shifty
12 - Quasar

Please find a workflow attached that bins your sample data into equal groups based on the Value column using the Tile tool:

 

Shifty_0-1652894040690.png

 

It doesn't group the columns the same way as you but the groups are equal by value.  Let me know if that works as expected.

 

grazitti_sapna
17 - Castor

@DHodges , this is as close as I could get to your solution. Please have a look.

 

grazitti_sapna_0-1652897928600.png

grazitti_sapna_1-1652897940391.png

 

I am not sure if this is what you are looking for. But if yes I hope it helps!

 

Thanks!

Sapna Gupta
Qiu
21 - Polaris
21 - Polaris
Labels
Top Solution Authors