Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Accumulation - include first row in totals

Hi,

I'm having an issue with my accumulation function. I need it to include the value on the first row as well. Below is the output I am currently experiencing, however what I was expecting to see is in the "Running Total" column - 75.73% on the first row and the subsequent values adding on top of the initial value. Any assistance would be greatly appreciated.

Here is how the columns are being calculated:

Relative Total: sum(count) WITH relative option selected

Total Count: sum(count) WITHOUT relative option selected

Running Total: Above(TOTAL Column(1)) + If(Above(TOTAL Column(3)) > 0, Above(TOTAL Column(3)), 0)

7 Replies
robert_mika
Master III
Master III

Does this help:

if(rowno()=1,sum([Relative Total]),RangeSum (above(sum([Relative Total]),0,RowNo())))

This 

is different data set but as you see is working

Not applicable
Author

Hi Robert,

Thank you for your reply but using your solution fills all of the rows with 0%test.png

robert_mika
Master III
Master III

I'm at home using PE so I can not ask for qvw file unless you can wait till tomorrow when I at work.

But if you can post sample of your data I can look at this again

Not applicable
Author

Here is a .csv of the raw data. In the table i'm rolling the data up to Month-Year

ramoncova06
Specialist III
Specialist III

This works for me

if(RowNo(total) = 1,column(1)/sum(total cnt),

rangesum(column(1)/sum(total cnt),Above(total [Running Total]))

)

Not applicable
Author

Thank you for the reply Ramon. Unfortunately using your solution is not accumulating the relative percentage.Is there any other options i need enabled?test.png

anbu1984
Master III
Master III

Running Total: Alt(Above( Column(3)),0)+Sum(cnt)

Running Total %: Column(3)/ Sum(TOTAL cnt)*100