Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
madmax88
Creator II
Creator II

Share of Total

Hi all,

I have a question. I have following table

   

CustomerProductValue
A110
A25
A310
B110
B20
B35
C10
C20
C310

Goal is to find out the share of a product in a Portfolio of a customer. If I select Product 1, I want to know the share of product 1 to all products of each customer. In this case it would give me following results:

Dimension Selected: Product 1:

   

CustomerShare
A40%
B67%
C0%

How should be the expression in set Analysis?

With my Expression I get only the share of a selected product to all products for each customer:

sum({$<criteria_1={'yes'}>}Value)/sum({$<criteria_1={'yes'}>}Total <Customer> Value)

In this Case I would become this:

A 50%

B 50%

C 0%

Thanks

1 Solution

Accepted Solutions
sunny_talwar

Try this in that case

Aggr(Sum({$<criteria_1 = {'yes'}>} Value)/Sum({$<criteria_1 = {'yes'}, Product>} TOTAL <Customer, Container> Value), Customer, Container, Product)

View solution in original post

22 Replies
sunny_talwar

May be this

Sum({$<criteria_1={'yes'}>}Value)/sum({$<criteria_1={'yes'}, Product>}Total <Customer> Value)

madmax88
Creator II
Creator II
Author

perfect, thanks!

Will try in the next days and let you know if it works

sunny_talwar

Sounds good

madmax88
Creator II
Creator II
Author

Short Update:

The Expression in a table seems to work:

   

Product CategoryProduct SubcategoryProductCustomerValueShare
XAQ12057%
XAW11029%
YBE1514%
XAQ2525%
XAW2525%
YBE21050%

Now I have an additional Value (Performance by customer). In the table it is correct (Same Performance for each product by customer-->I only have the Performance by customer and not by product).

Now I Need a Point Diagramm (Dimension Product, X-Axis "Share" and Y-Axis "Performance by customer"). If I select a random customer the Point Plot is correct. But If i want to Show the Plot for all customer (no selection), the X-Axis ("share") is wrong. How is it possible?

sunny_talwar

Would you be able to share a sample to show what you have?

madmax88
Creator II
Creator II
Author

Example should be the table above. Goal is a Point Plot with following expressions:

Dimension: Product

X-Axis: Share: Sum({$<criteria_1={'yes'}>}Value)/sum({$<criteria_1={'yes'}, Product>}Total <Customer> Value)

Y-Axis: Performance: Median({$<Criteria_2={'yes'}>}Performance/100

Now If I select Customer 1, the Point Plot Shows the Performance of Customer 1 and the Share of all Products. E.g. Performance is 1.5% and customer 1 has 3 products, then the plot Shows all 3 products by share (X-Axis) and each product has the same Performance of 1.5% (y-Axis).

Now I de-select the customer and have again all Positions of all customers. There the share is wrong calculated.

Wrong means that the share is not calculated by each customer, but it calculates she share of each product to all products from all customer

Does it help you?

sunny_talwar

I am not sure I am able to understand still... I am not even entirely sure if I will be able to recreate the chart with your issue and hence was asking you to share an app (may be with the above data) and recreate the chart and issue for me so that I can see and play around with it.

madmax88
Creator II
Creator II
Author

how can i share an example or screenshot?

If it doesnt work: On the Point Chart it Shows me the share of Product over all customer and not the share of product in the Portfolio of a customer