Skip to main content
Announcements
Qlik Introduces a New Era of Visualization! READ ALL ABOUT IT
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Excluding Outliers from Avg Calculations at the dimension level

All,

I need to plot monthly average trend. Each month behaves differently hence the need to exclude outliers at the month level. This calculation needs to be dynamic if I need to look at the trend by a certain category (the outliers need to be recalculated at the category level by each month)

I have attached a sample QVF.

7 Replies
sunny_talwar

Is the outliers in one direction only or do we have outliers in both directions?

Anonymous
Not applicable
Author

‌yes. I just want to exclude the upper outliers.

sunny_talwar

May be this

Avg(Aggr(If(Values <= Fractile(TOTAL <Cat, Dates> Values , 0.75) +  1.5 *(Fractile(TOTAL <Cat, Dates> Values , 0.75) - Fractile(TOTAL <Cat, Dates> Values , 0.25)), Values), Cat, Values, Dates))

Anonymous
Not applicable
Author

When I tested your solution, the average is higher than the normal average calculation. That shouldn't be the case if we're excluding the upper outliers, Otherwise it works, just not with the numbers I expect

sunny_talwar

I saw similar problem, but I am not sure what might be issue... Would you be able to share the raw data behind this app in an Excel file?

Anonymous
Not applicable
Author

Please find the raw data attached! I also noticed you're using Total in your outlier calculation and that will have a uniform outlier for all the dimension values. I want each dimension to have its own outlier

sunny_talwar

I am heading out for the day today, but will try to take a look today in the evening or tomorrow morning.

Best,

Sunny