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: 
shyamcharan
Creator III
Creator III

Count of Days with Fractile function

Hi Experts,

I have data which has the ID, week, dates in the week, the response time in seconds and minutes as shown below.

    

IDWeekDateResponseTime_Secondds        Min
1101-01-201781913.65
2101-01-20174958.25
3101-01-201776812.8
4101-01-20175879.783333
5101-01-20174898.15
6101-01-20175108.5
7101-01-201797516.25
8101-01-201763810.63333
9101-01-201787214.53333
10101-01-201781413.56667
11101-01-20175549.233333
12101-01-20172163.6
13102-01-20175298.816667
14102-01-201794515.75
15102-01-20172414.016667
16102-01-201776112.68333

As shown in the attached QVW, chart 1 has the 50th percentile values calculated for each individual day using the Fractile function.

In chart 2, I would need to show the count of days in a week that had the 50th percentile value >= 10.5.

The expected result from the data in attached QVW should be Week 1 = 3 and Week 2 = 5 days.

However, I am unable to get it worked.

Can you please help. Appreciate your response.

Regards,

Shyam

24 Replies
Kushal_Chawda

Should be calculation logic won't change in Qlik right?

tresesco
MVP
MVP

You are right while saying 'in this scenario'. Since, date is a dimension being used in the chart (or in aggr) and you use the same field in the set analysis( Date={"...), putting distinct works; again 'in this scenario'. . However, had there been more dimensions in aggr/chart and not in the resultant chart.. this would not work.

sunny_talwar

Pata nai yaar... I don't fully trust the Fractile function in Qlik.... they have a very unique way of calculating Percentile... whick is why I am hesitant to say that they are the same or not

sunny_talwar

But in that case you would have needed to modify your solution also, isn't it

its_anandrjs

shyamcharan
Creator III
Creator III
Author

Thank you all for quick response.

Thank you Tresesco, Kushal and sunny. All your solutions work. Great!!

sunny_talwar

Check how Fractile gets calculated in Qlik

What is the exactly calculation of the fractile function?

Kushal_Chawda

Yes, that is why I specified "this scenario"

Kushal_Chawda

shyamcharan‌  I would suggest to use set analysis solution as it is always advised. If condition with Aggr impacts the performance of the chart (if data is huge, otherwise no problem).

tresesco
MVP
MVP

Yes, absolutely. I only wanted to establish - the set analysis insensitivity of chart dimension. And yes, kush141087‌'s solution is better 'in this scenario'.