Qlik Community

QlikView Layout & Visualizations

Discussion Board for collaboration on QlikView Layout & Visualizations.

matthias_wiciok
Contributor

Color fractiles of Chart

Hello everybody,

I got the following problem: I have got a chart showing the number of invoices of each user. Now I want to color the 20% of the users in a different color. I got something like this:

Dimension:      user_name

Expression:     count(invoice_number)

Backgroundcolor Expression:     if(count(if(user_name = user_name, invoice_number, 0)) > fractile(aggr(count(invoice_number), user_name), 0.8), color1, color2)

I always got color2

it works if I change the fractile expression by a single number (i.e. 10).

But I want to get the boarder dynamically.

Can you help me?

Tags (3)
1 Solution

Accepted Solutions
MVP
MVP

Re: Re: Re: Re: Color fractiles of Chart

See attached sample. I have done for top 10% . You can modify accordingly.

9 Replies
Not applicable

Re: Color fractiles of Chart

you can use this, may be cany help you;

regards!!!

Color.jpg

matthias_wiciok
Contributor

Re: Re: Color fractiles of Chart

I don't think so.

See the attachment.

I want A and B got diffrent color than the rest.

matthias_wiciok
Contributor

Re: Re: Color fractiles of Chart

Has nobody a solution to this problem?

c_gilbert
Contributor II

Re: Color fractiles of Chart

Are you just wanting 20% of the users to go a different colour? E.g. The top 20% users with the most invoices?

... Or the users who have a number of invoices that is over 20% of the total to be a different colour?

lironbaram
Honored Contributor II

Re: Re: Re: Color fractiles of Chart

have a look at the attach example

matthias_wiciok
Contributor

Re: Re: Re: Color fractiles of Chart

It is the second. So, for example, there are 100 invoices in the system and I want to color the top 20%, then I need to color those bars of users, who got in sum more than 20 invoices. Person A got 15 invoices, person B 6, Person C 5 and the rest 1 invoice in their account. In this scenario I would like to color the bars of A and B.

matthias_wiciok
Contributor

Re: Re: Re: Color fractiles of Chart

Hi Liron,

to be honest, I am not sure what you are calculating in your turn-around. I will try to understand your solution and will give Feedback.

MVP
MVP

Re: Re: Re: Re: Color fractiles of Chart

See attached sample. I have done for top 10% . You can modify accordingly.

matthias_wiciok
Contributor

Re: Re: Re: Re: Color fractiles of Chart

Thank you very much. I just have to modify the fractile-part and this will be.

Community Browser