6 Replies Latest reply: Aug 22, 2017 11:00 AM by francesco xodo

# Show accumulated value when zooming in line chart

Hello everybody,

I'm trying to find a solution about a problem but I haven't been able so far so I'll ask for your help

I have a line graph with the expression RANGESUM(ABOVE(SUM(Value),0,RowNo())) to get accumulated value over months.

If I zoom in the graph, which is equivalent to select a subset of months, the value of the first selected month is not the accumulated value of the preceding months, but is its punctual value.

For example, if I select month 3 and 4 I would expect 13 and 23, instead I get 4 and 14.

Is there any workaround to solve this problem?

Thanks

• ###### Re: Show accumulated value when zooming in line chart

Try this

RangeSum(Above(Sum({<Month>}Value), 0, RowNo())) * Avg(1)

• ###### Re: Show accumulated value when zooming in line chart

stalwar1, guy, you really are a genius

• ###### Re: Show accumulated value when zooming in line chart

I guess I got a chance to learn from one of the best people out there...

• ###### Re: Show accumulated value when zooming in line chart

Thanks a lot Sunny! Can you explain me the logic behind that or is it too long?

• ###### Re: Show accumulated value when zooming in line chart

Part 1 - Ignore selection in Month field so that your accumulation doesn't restart based on your selection

RangeSum(Above(Sum({<Month>}Value), 0, RowNo()))

Part 2 - Because we ignored selection in Month, I would see all the Months even when I have selected 2 or 3 months. To make the value for the other months to go away, I have to force them to be 0. In order to do that I multiply with Avg(1). Avg(1) will be 1 for months selected and 0 for any month which has not been selected.

Does this make sense?

• ###### Re: Show accumulated value when zooming in line chart

Totally makes sense. I knew about the first part but didn't know about the second one. Thanks again!