Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
2 years ago

Clustering and Groupin

Hello everyone,

 

I have created the follwing table:

 

So my mix% dynamic is the weight of sales(arranged in descending order) for each SMC by department/region, then I calculated cumulative mix% to be able to create cluster of products: A if cumulative is less than 25%, then B if less than 50%, C if less than 75% else D.

 

Here is my DAX for cumulative% : 

So I am using windows function to calculate cumulative line by line and I need to use "SMC" which is kind of SKU.

 

What I would like to do now is be able to remove the column SMC so that I have an aggregation clusterwise, and in place of column SMC, I want to display number of SMC in the cluster, then sum of sales for the cluster, the cumulative of last line of the cluster,  example: 

 

 

Any leads please? let me know if additional information is needed.

 

Thanks,

Ekta

1 Reply