Forum Discussion

JJolie's avatar
JJolie
Copper Contributor
Mar 26, 2020

Excel PivotTable Average Subtotals - incorrect results

One recurring problem that I come across is the discrepancy in the Average calculation in the Subtotals within a PivotTable. What am I missing?

 

Here’s my example:

 

Thanks in advance!

 

5 Replies

  • SergeiBaklan's avatar
    SergeiBaklan
    Diamond Contributor

    JJolie 

    What you calculate manually is average of averages, and pivot table calculates in total average on all items.

    Other words, in PivotTable you have something like (a1+a2+a3)/3 and (a5+a6)/2 for the items and (a1+a2+a3+a5+a6)/5 for grand total.

     

    What you calculate manually is ( (a1+a2+a3)/3 + (a5+a6)/2 )/2

    • JJolie's avatar
      JJolie
      Copper Contributor

      SergeiBaklanIs there any way to get the PivotTable options to choose the correct option?

      • SergeiBaklan's avatar
        SergeiBaklan
        Diamond Contributor

        JJolie 

        Again, correct or not correct depends on what exactly we would like to calculate. If average of all sublevel averages, not the average for entire level - when we need to add data to data model, write DAX measure which calculates above and use it in PivotTable. 

Resources