Forum Discussion

Chanleakna123's avatar
Chanleakna123
Post Prodigy
8 years ago
Solved

Moving Average

 

Hi everyone, 

I wanna calculate Average Moving on by month. 
If there're another Date in NOV , that would be the calculation of the Average from Jan to Nov. 
Do you have any idea ? I tried the calculation above , looks it's not what i'm looking for. 

Thanks you so much for your all response. 

Best Regards, 
Chanleakna Hang 

  • Chanleakna123

     

    You can take a look at this article. You can also try with following DAX formula and you can adjust it based on your table structure. Attached PBIX file can be a reference.

     

    Average EUR = 
    CALCULATE (
        AVERAGE ( Table1[EUR] ),
        FILTER ( ALL ( Table1[Date] ), Table1[Date] <= MAX ( Table1[Date] ) ),
        VALUES( Table1[Description] )
    )
    

     

    Best Regards,
    Herbert

4 Replies

  • v-haibl-msft's avatar
    v-haibl-msft
    Microsoft Employee

    Chanleakna123

     

    You can take a look at this article. You can also try with following DAX formula and you can adjust it based on your table structure. Attached PBIX file can be a reference.

     

    Average EUR = 
    CALCULATE (
        AVERAGE ( Table1[EUR] ),
        FILTER ( ALL ( Table1[Date] ), Table1[Date] <= MAX ( Table1[Date] ) ),
        VALUES( Table1[Description] )
    )
    

     

    Best Regards,
    Herbert