6 Replies Latest reply: Jan 4, 2013 11:31 AM by Dennis Hoogenboom

# Top 20 % Costumers and top 20 % products

Dear Specialists,

I would like to divide my customers and products into 4 quarters. Based on Sum(Sales):

Group1. Top 20% Costumers and the top 20% products.

Group2. Top 20% Costumers and the other 80% products

Group3. Other 80% Costumers and the top 20% products.

Group4. Other 80% Costumers and the other 80% products

All connected to my selection (so flags creation in the loading script is not an option)

Dennis.

• ###### Re: Top 20 % Costumers and top 20 % products

Create a input variable for customer and products n use the variables in ur expression with sales.

So after creating input variables u can input any %  in customer n products varaible...so in ur case u can select 20 n 80 to get the value of sales.

• ###### Re: Top 20 % Costumers and top 20 % products

Thanks for your reply but how would that give me the result I am looking for?

See the attached file for an example.

• ###### Re: Top 20 % Costumers and top 20 % products

Does anybody know how I should solve this?

Thanks.

• ###### Re: Top 20 % Costumers and top 20 % products

He wrote:

Hi Dennis,

Please find the attached modifed application where I have tried to generate two separate field named as "Customers Group" and "Product Group".

You could also use this expression in button and further work on.....

In-case of any difficulty let me know...

Regards,

Nitin Jain

See the attached file for his nice solution.

Thanks jain.nitin88

• ###### Re: Top 20 % Costumers and top 20 % products

The only problem is that this shows the (in the case of the customers) the top 80 % of the customers.

I want the few customers that represent 80 % of the total of Sum(Sales). (not 20 as I said in the example)

So the customers that represent 80% of the Sales, which is different then 80% of the customers based on the ranking.

• ###### Re: Top 20 % Costumers and top 20 % products

Extra information:

What I want is:

If my total sales is 100, I want to see the top customers that are responsable for x% (let say 80) of that sales.

When I use, in my dimension color :

=if(RangeSum(Above(Total Sum(Sales),0,RowNo(TOTAL))) > Sum(Total Sales)* '0,8' ,RGB(200,100,100),RGB(125,222,120))

I got exacly the right colors for the right customers

What I want as a dimension is something like:

=if(RangeSum(Above(Total Sum(Sales),0,RowNo(TOTAL))) > Sum(Total Sales)* '0,8' ,'GroupC1', 'GroupC2')

But that doesn't work.