Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!
Hi,
Trying to work out how to calcuate the moving avereage if the last 3 values in data set by group.
Essentially Calculate the last 3 values in a column.
eg
Group Value Shift
1 2 D1
2 4 D1
3 2 D1
1 3 D2
2 3 D2
3 5 D2
1 5 D3
2 0 D3
3 5 D3
I Would expect the result to report in D1
1 2 3
D1 3.33 2.33 4
Any help would be appreciated
Thank you
Solved! Go to Solution.
You may view the code generated by Quick measure Rolling average.
Hi @BrendanC89 ,
The table provided is this the final data that you want to derive the moving average.
Is there any date in the table ? What are the slicers you will be using to view data ?
Cheers
CheenuSing
Hi,
thanks for the assistance .
My date table could be the "shift" column. which could be set up as Day 1 Night 1 Day 2 night 2 etc or by the following
24/7/19 6AM
24/7/19 6PM
25/7/19 6AM
25/7/19 6PM
etc etc
Yes the final table is my desired output and would be best displayed as a table or matrix
Hadnt given any thought to using slicers for this.
Thank you agian,
Brendan
You may view the code generated by Quick measure Rolling average.
User | Count |
---|---|
141 | |
113 | |
104 | |
78 | |
64 |
User | Count |
---|---|
136 | |
125 | |
107 | |
70 | |
61 |