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

Calculate Average from current Quarter

Hi, Im trying to get the correct value in the sample below

RoE = SUM(NetProfit) / SUM(Capital) * 12

And "Avg RoE" needs to be AVG(RoE) for the current Quarter,

ie: the correct value for 2018/Q1 = AVG(47.7, 89.3, 36.1) = 57.7%

image.png

image.png

I have try with Aggr, and RangeAvg( Before...) without success

How can I achieve this?

Thanks in advance

Labels (2)
1 Solution

Accepted Solutions
agni_gold
Specialist III
Specialist III

Change you Avg ROE expression to below : 

 

=Avg(
Aggr(
(Sum( {<ID_Class = {5}>} Balance)
/
Sum( {<Class = {'Patrimonios'}>} Balance)
* 12),Month))

 

see attached file

 

View solution in original post

2 Replies
agni_gold
Specialist III
Specialist III

Change you Avg ROE expression to below : 

 

=Avg(
Aggr(
(Sum( {<ID_Class = {5}>} Balance)
/
Sum( {<Class = {'Patrimonios'}>} Balance)
* 12),Month))

 

see attached file

 

rfigueroa
Contributor III
Contributor III
Author

Thank You