Forum Discussion

jco1987's avatar
jco1987
New Member
6 years ago
Solved

Average data from one column based on another column group by a third column

I have the following data in power BI (columns 1 - 3).  I'm struggling with the DAX to create a column (column 4) with the average of the Values (column 3) for Weeks 9 and 10.  The value in the new c...
  • AndreyBear's avatar
    6 years ago

     

    Column = AVERAGEX(
        filter('Table',
            'Table'[Facility]=EARLIER('Table'[Facility])
            &&('Table'[Week]="Week9"||'Table'[Week]="Week10"))
        ,'Table'[Value])