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

Level up your Power BI skills this month - build one visual each week and tell better stories with data! Get started

Reply
ViralPatel212
Resolver I
Resolver I

Rolling Average

Hello Team,

 

I was wondering if i could like a average per row across 5 days dax. 

Some background: Trades is a measure with counts the number of occurenaces happens in a table (i.e. counting duplicates)

 

Here is my data image: 

ViralPatel212_0-1708958848857.png

I can replicate it in excel very simple: with a simple formula =AVERAGE(C2:C6) in cell d2 and in d3 is goes down by 1 i.e d3 cell = average(C4:C7) etc

ViralPatel212_1-1708959119558.png

thanks

viral

 

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@ViralPatel212 , You can use these measures

 

Using date table

Rolling 5 = CALCULATE(Averagex(Values('Date'[Date]) , [Your measure]) ,DATESINPERIOD('Date'[Date],MAX('Date'[Date]),-5,Day))

 

Using window

 

Rolling 12 = CALCULATE(Averagex(Values('Date'[Date]) , [Your measure]) , WINDOW(-4,REL, 0, REL, ADDCOLUMNS(ALLSELECTED('Date'Date]),ORDERBY([DAte],asc)))

 

Use new visual calculation

MOVINGAVERAGE([Net], 5)

 

 

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

View solution in original post

3 REPLIES 3
amitchandak
Super User
Super User

@ViralPatel212 , You can use these measures

 

Using date table

Rolling 5 = CALCULATE(Averagex(Values('Date'[Date]) , [Your measure]) ,DATESINPERIOD('Date'[Date],MAX('Date'[Date]),-5,Day))

 

Using window

 

Rolling 12 = CALCULATE(Averagex(Values('Date'[Date]) , [Your measure]) , WINDOW(-4,REL, 0, REL, ADDCOLUMNS(ALLSELECTED('Date'Date]),ORDERBY([DAte],asc)))

 

Use new visual calculation

MOVINGAVERAGE([Net], 5)

 

 

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

@amitchandak That worked partly. I have a identifier in my date table called Weekend. If its a Weekend say YES else No. 

How do i tweak the measure to exlcude weekend?

thanks

Viral

h

Helpful resources

Announcements
April Power BI Update Carousel

Power BI Monthly Update - April 2026

Check out the April 2026 Power BI update to learn about new features.

Fabric SQL PBI Data Days

Data Days 2026 coming soon!

Sign up to receive a private message when registration opens and key events begin.

New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.