Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

How to: percentage of whole (x-axis) in chart

Hello,

Considering a columnchart with {A,B,C} as series and {1, 2 ,3, 4} as x-axis.

The measure I'd like would be an count(Y) but as an percentage of [the total count(Y) from whole x-axis for that specific serie]

In other words, if we're looking at an example of A:

X-axis-member:     Count(Y)-measure:          The %-measure I'd like:

1                          25                                  25/52 => 48%

2                          5                                    5/52 => 10%

3                          12                                  12/52 => 23%

4                          10                                  10/52 => 19%

                         _____

  total count(Y) =   52

The results would be different for each serie, as we calculate percentages not against the overall total but for the total of that one serie.

I belive i need a set expression but cant figure out how to do it.

Thank you

1 Solution

Accepted Solutions
Not applicable
Author

try like:

count(Y)/count(total Y)

Regards

R

View solution in original post

3 Replies
Not applicable
Author

try like:

count(Y)/count(total Y)

Regards

R

Not applicable
Author

Have you tried count(y)/count( total (y)?

Could you maybe upload a qvw file it might be easier to help you.

Not applicable
Author

Cheers!