Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
robmarr789
Contributor
Contributor

cumulative total for profit %

Hi attached I have a chart showing cumulative sales and cos. I also want to display profit % cumulatively but it will only show the % for each month. If I change the expression to full accumulation it will then add up each months percentage which does not work for profit percentage.

 

Does anyone know how to fix this? If you could reattach with the solution it would really help.

Labels (1)
1 Solution

Accepted Solutions
sunny_talwar

Try this expression with no accumulation

=1 - (RangeSum(Above(Sum({<Year = {"$(=TodayYear)"}>} COS), 0, RowNo()))/RangeSum(Above(Sum({<Year = {"$(=TodayYear)"}>} sales), 0, RowNo())))

View solution in original post

2 Replies
sunny_talwar

Try this expression with no accumulation

=1 - (RangeSum(Above(Sum({<Year = {"$(=TodayYear)"}>} COS), 0, RowNo()))/RangeSum(Above(Sum({<Year = {"$(=TodayYear)"}>} sales), 0, RowNo())))
robmarr789
Contributor
Contributor
Author

perfect!