Skip to main content
Announcements
See what Drew Clarke has to say about the Qlik Talend Cloud launch! READ THE BLOG
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Set analysis to calculate average

Hello guys, I have used set analysis to calculate average in a gauge. This is the formula:

=avg({$<[DepartmentAssuranceFlag] = {"0}, RiskName={'CPD'}>} Rating)

The score is 2.78

However, if I work out the average in Excel the score is 2.52 (See attachment for clarity)

Could you please confirm that my QV formula is correct? If not, could you pleasesuggest right formula to calculate the average, given the conditions in the formula?

Thank you for your support.

1 Solution

Accepted Solutions
Gysbert_Wassenaar

Based on your excel file and using your expression (minus the typo) I get as average 2.57 in both Qlikview and in Excel.

avg({$<[DepartmentAssuranceFlag] = {0}, RiskName={'CPD'}>} Rating) yields 2.57


talk is cheap, supply exceeds demand

View solution in original post

2 Replies
kaushiknsolanki
Partner Ambassador/MVP
Partner Ambassador/MVP

Hi,

     There is one mistake in your expression. Correct expression is

     =avg({$<[DepartmentAssuranceFlag] = {"0"}, RiskName={'CPD'}>} Rating)

Regards,

Kaushik Solanki

Please remember to hit the 'Like' button and for helpful answers and resolutions, click on the 'Accept As Solution' button. Cheers!
Gysbert_Wassenaar

Based on your excel file and using your expression (minus the typo) I get as average 2.57 in both Qlikview and in Excel.

avg({$<[DepartmentAssuranceFlag] = {0}, RiskName={'CPD'}>} Rating) yields 2.57


talk is cheap, supply exceeds demand