Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
5 years ago

Average column in Matrix table

Hi All,

 

I need to include Average column in matrix table that should look like the table below. Can anyone show how I can include the average column in the matrix table?

 

[Updated] Also, the week columns are dynamic such that I have a Week slicer to determine the latest week and the Matrix will show the rolling 5 weeks based on the selection (i.e., If Week slicer is filtered to Wk2, Matrix table will display Wk6 to Week 2. If slicer is filtered to Wk 1, Matrix table will display Wk5 to Wk 1).

 

[Updated] I have a measure that is created to display rolling 5 weeks in Matrix table. 

Actual_5wks: 

CALCULATE([Actual], FILTER(Dim_Period, Dim_Period[Week Index]>=([Selected_WeekID]-4) && Dim_Period[Week Index]<= [Selected_WeekID]))

 

To calculate Average : Total / Count of no of week value (i.e., Avg of Product B --> 20/3 = 6.7)

 

Rows: Country, Products

Columns: Week

Values: Units

 

P/S: I'm unable to share the pbix ><

 

Regards,

BK

4 Replies