Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

How to add dynamic expression to Guage Chart Title

Hi Guys

I have got three guage charts, One with Total Cost, and other two are broken down between Pay and Non pay.

My problem is, the amount in the bottom half of the guage charts, as you can see it works fine for the "Overall Performance" as there is no filter to it, however how to put a filter for Pay and Non Pay. Can we put something in Sum as a condition to only pick up 'Pay' and 'Non Pay'.

Expression for Title in Chart: =num((Sum(Budget_YTD)-Sum(Actual_YTD)),'#,##0;(#,##0)')

For the guage itself, I have created a calculated dimentions with expression to get Pay and Non Pay: =CostCat='Pay Expenditure'

error loading image

Any ideas are most welcome

1 Solution

Accepted Solutions
Not applicable
Author

Hi,

you can use the SET Analysis to filter: =num((Sum(Budget_YTD)-Sum(Actual_YTD)),'#,##0;(#,##0)')

--> "sum( {$ <condition = {'Pay'}> } Budget_YTD)" and similar for sum(Actual_YTD)

Means:

$ = actual selection (user)

< between (here) are the exeptions >

and all aroound are {}

This should help

Roland

View solution in original post

5 Replies
Not applicable
Author

How about making the dimension for the pay /non-pay gauges calculated, for example for Pay Expenditure

if (Cat = 'Pay Expenditure', Cost)

amd then make the dimension 'suppress when value is null'

Regards,

Gordon

Not applicable
Author

Hi,

you can use the SET Analysis to filter: =num((Sum(Budget_YTD)-Sum(Actual_YTD)),'#,##0;(#,##0)')

--> "sum( {$ <condition = {'Pay'}> } Budget_YTD)" and similar for sum(Actual_YTD)

Means:

$ = actual selection (user)

< between (here) are the exeptions >

and all aroound are {}

This should help

Roland

Not applicable
Author

Thank you for reply Gordon,

I think, Chart title expression is independent to the calculated dimentions or any other expression in guage chart.

So, making gauge dimension calculated is a very good practice and I will adopt it, but It doesn't solve the very problem of displaying correct figures at the bottom of the guege chart in red, which is driven by Title Expression. It works fine when I explicitly select the Category Pay from list box of Expense category but when no specific selection is made, it only shows me value for all, and not for a specific category.

In a nutshell, at any given point, the gause should display the total and the breakdown by exp category together.

Hope this make sense.

Sap

Not applicable
Author

Hi Roland

I am going to give SET analysis a go and let you know how it goes.

Thanks you for the reply.

Sap

Not applicable
Author

Hi Roland

You're the man. !!!

Set analysis worked like a treat.

Still early days for me with Qlikview, I like to learn by myself but would you reckon a structrued training session would be ideal? I am not paying, probs, get my employer to pay for it. Stick out tongue

Thanks once again to Roland and Gordon.

Regards

Sap