Skip to main content
Announcements
Introducing Qlik Answers: A plug-and-play, Generative AI powered RAG solution. READ ALL ABOUT IT!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Show count of branches where branch value > avg value?

I am trying to figure out how to show a count, by month, of branches whose paid percent is greater/less than that month’s average paid percent (across all branches).

Please see the qvw attached for sample data.  If I add branch as a dimension, I can get an individual count.  But I can’t figure out how to either roll it up to the month level or (ideally) do it w/o having branch as a dimension since I don't really need it displayed. 

What I have:

7-29-2011 3-11-50 PM.png

What I want:

7-29-2011 3-04-03 PM.png

Any suggestions?

1 Solution

Accepted Solutions
swuehl
MVP
MVP

Hi,

use

=count(aggr(if((Sum(total<Branch,Month>Paid)/Sum(total <Branch,Month>Billed))>(Sum (total <Month> Paid) / Sum (total <Month> Billed)),count(distinct Branch)) ,Branch, Month))

as expression for Branches > Co Avg.

Stefan

View solution in original post

2 Replies
swuehl
MVP
MVP

Hi,

use

=count(aggr(if((Sum(total<Branch,Month>Paid)/Sum(total <Branch,Month>Billed))>(Sum (total <Month> Paid) / Sum (total <Month> Billed)),count(distinct Branch)) ,Branch, Month))

as expression for Branches > Co Avg.

Stefan

Not applicable
Author

That's exactly what I needed - thanks!