Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Anonymous
Not applicable

Taking the average of a measure

Moving Range = 
VAR EarlierTime =
    CALCULATE (
        MAX ( 'table'[StartDate] ),
        FILTER (
            ALLSELECTED (  'Table'[StartDate] ),
             'table'[StartDate] < SELECTEDVALUE (  'table'[StartDate] )
        )
    )
VAR EarlierMeasureValue =
    CALCULATE ( SUM (  'table'[Operating Efficency]),  'table'[StartDate] = EarlierTime )
RETURN
    ABS ( EarlierMeasureValue - SUM ( 'table'[Operating Efficency]) )

 

I have this measure and I'm trying to take the average after it has gone through all the rows. Any ideas on how I could go about doing this?

1 ACCEPTED SOLUTION
v-easonf-msft
Community Support
Community Support

Hi ,  @Anonymous 

According to you description, you can try to use measure like that:

Measure = AVERAGEX(Table, Table[Moving Range])

 

If I misunderstood you problem ,please let me know.

In addition ,you can kindly share your sample data and expected result if you don't have any Confidential Information.

 

Best Regards,

Community Support Team _ Eason

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

3 REPLIES 3
mwegener
Most Valuable Professional
Most Valuable Professional

Hi @Anonymous 


is your problem solved?

 

If I answered your question, please mark my post as solution, this will also help others.
Please give Kudos for support.

Did I answer your question?
Please mark my post as solution, this will also help others.
Please give Kudos for support.

Marcus Wegener works as Full Stack Power BI Engineer at BI or DIE.
His mission is clear: "Get the most out of data, with Power BI."
twitter - LinkedIn - YouTube - website - podcast - Power BI Tutorials


v-easonf-msft
Community Support
Community Support

Hi ,  @Anonymous 

According to you description, you can try to use measure like that:

Measure = AVERAGEX(Table, Table[Moving Range])

 

If I misunderstood you problem ,please let me know.

In addition ,you can kindly share your sample data and expected result if you don't have any Confidential Information.

 

Best Regards,

Community Support Team _ Eason

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

mwegener
Most Valuable Professional
Most Valuable Professional

Hi @Anonymous ,

 

look at this.

averagex-function-dax 

 

Regards,

Marcus

Dortmund - Germany
If I answered your question, please mark my post as solution, this will also help others.
Please give Kudos for support.

Did I answer your question?
Please mark my post as solution, this will also help others.
Please give Kudos for support.

Marcus Wegener works as Full Stack Power BI Engineer at BI or DIE.
His mission is clear: "Get the most out of data, with Power BI."
twitter - LinkedIn - YouTube - website - podcast - Power BI Tutorials


Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.