Search code examples
matrixpowerbiaveragemetrics

Power Bi - Add Total Average column in Matrix


Hi I am trying to add a AVERAGE column in a matrix, but when I put my metric added the average per column, but I need a total AVERAGE and total at the end just once

What I have: enter image description here

What I need:

Group Maria Pedro average total
First 4 6 5 10
Second 5 10 7.5 15

Regards


Solution

  • Following the example detailed in the sample data table, to get the Total you could add the following measure;

    Total By Group = CALCULATE( SUM(AverageExample[Maria]) + SUM(AverageExample[Pedro]))
    

    and to average

    Average By Group = [Total By Group] / 2
    

    Based on the first three columns, this will provide

    Total and Average