Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
3 years ago
Solved

How to : Matrix Average values and sum subtotal

Hi eveybody,

I have some values like this

and Matrix Object like that

For each REF i have the monthly average (OK, it's what i want) but for the PTF subtotal i wish the sum of averages not the average

for example : PTF1/202202 (aaaaa+bbbbb = 6.00+3.50) = 9.50 not 4.75

How can i do that ?

Thanks

  • Anonymous's avatar
    Anonymous
    3 years ago

    Unfortunatly, isn't ok sub total PTF isn't equal to sum(ref)

    I have found an another method with transformation data : Group By

    = Table.Group(#"Added Custom", {"PTF", "yyyymm", "REF"}, {{"ValueMoy", each List.Average([Value]), type nullable number}})

    It's ok

     

     

2 Replies

  • Hi,

    try this measure

    Measure = if (HASONEVALUE('Table'[REF]),AVERAGE('Table'[Value]),calculate(AVERAGE('Table'[Value]), ALL('Table'[Date])))
     
    you will obtain this

    If this post is useful to help you to solve your issue, consider giving the post a thumbs up and accepting it as a solution !

     

    • Anonymous's avatar
      Anonymous
      Not applicable

      Unfortunatly, isn't ok sub total PTF isn't equal to sum(ref)

      I have found an another method with transformation data : Group By

      = Table.Group(#"Added Custom", {"PTF", "yyyymm", "REF"}, {{"ValueMoy", each List.Average([Value]), type nullable number}})

      It's ok