
Re: Calculating Cumulative Percentage of Total by Column (Pivot Table)
Sunny Talwar Oct 22, 2018 8:30 AM (in response to Elin Tham)How about this
RangeSum(Before(Count({<[Criteria]>}[ID]), 0, ColumnNo()))/
Sum(TOTAL <WeekYearField> Aggr(RangeSum(Above(Count({<[Criteria]>} [ID]), 0, RowNo())), Flag, (WeekYearField, (NUMERIC))))

Re: Calculating Cumulative Percentage of Total by Column (Pivot Table)
Elin Tham Oct 23, 2018 5:06 AM (in response to Sunny Talwar )Thank you very much, Sunny!

Re: Calculating Cumulative Percentage of Total by Column (Pivot Table)
Elin Tham Oct 24, 2018 5:57 AM (in response to Sunny Talwar )Hi Sunny,
Sorry, but I have a few more questions.
What if I have another dimension "Flag Corrected" and I only want to show those Flag Corrected = Y in the Pivot Table? Is it possible to do so in the pivot table? I've tried to do Qlik Expression under row: =if(Flag Corrected = {"Y"}, Flag Corrected) but it doesn't seem to work.
I also would like to calculate the cumulative percentage of Flag Corrected = Y over the total cumulative count of ZZVALIDATED AEC flag. For example in Week 201827, the % for Flag Correct = Y should be 55/12,331 = 0.446% instead of 55/12,595=0.436%. Do you think it is possible to do so in a pivot table?
I've tried to create another pivot table to only show the Flag Corrected but am unable to get the cumulative percentage of Flag Corrected = Y over the total cumulative count of ZZVALIDATED AEC flag.
I'm using this expression:
RangeSum(Before(Count({<[Criteria]>}ID),0,ColumnNo()))/
Sum(TOTAL <WEEK> Aggr(RangeSum(Before(Count({<[Criteria with Flag = ZZVALIDATED AEC]>}ID),
0, ColumnNo())), Flag,(WEEK, (NumericCount))))

Re: Calculating Cumulative Percentage of Total by Column (Pivot Table)
Sunny Talwar Oct 24, 2018 7:53 AM (in response to Elin Tham)May be this for showing just Flag Corrected = 'Y'
RangeSum(Before(Count({<[Criteria], [Flag Corrected] = {'Y'}>}[ID]), 0, ColumnNo()))/
Sum(TOTAL <WeekYearField> Aggr(RangeSum(Above(Count({<[Criteria], [Flag Corrected] = {'Y'}>} [ID]), 0, RowNo())), Flag, (WeekYearField, (NUMERIC))))

Re: Calculating Cumulative Percentage of Total by Column (Pivot Table)
Sunny Talwar Oct 24, 2018 7:55 AM (in response to Elin Tham)I also would like to calculate the cumulative percentage of Flag Corrected = Y over the total cumulative count of ZZVALIDATED AEC flag. For example in Week 201827, the % for Flag Correct = Y should be 55/12,331 = 0.446% instead of 55/12,595=0.436%. Do you think it is possible to do so in a pivot table?
May be this
RangeSum(Before(Count({<[Criteria]>}[ID]), 0, ColumnNo()))/
Sum(TOTAL <WeekYearField, Flag> Aggr(RangeSum(Above(Count({<[Criteria]>} [ID]), 0, RowNo())), Flag, [Flag Corrected],(WeekYearField, (NUMERIC))))

Re: Calculating Cumulative Percentage of Total by Column (Pivot Table)
Sunny Talwar Oct 24, 2018 7:55 AM (in response to Elin Tham)Is there a third question?

