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

Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.

Reply
Anonymous
Not applicable

Rolling Average DAX to plot correctly on Column Chart

Hi All,

 

I have a problem with the measure of the 3mth rolling average to visualise it correctly on the graph. 

The data model is here: 

https://docs.google.com/spreadsheets/d/1naChcuZtjSbk0pVEi1xKuTZhSY7Rpabc0OCbmxowQME/edit?usp=sharing

 

I am using the formula below to calculate 3mth average 

Product3Mth = CALCULATE(SUM('Table'[Product A uncum]);DATESINPERIOD('Table'[Date];LASTDATE('Table'[Date]);-3;MONTH))/3

 

When I am plotting it as a table it is showing right values for each month. 

Table.PNG

 

But When I amplotting it in the column chart together with Product A Accumulated I am getting wrong value which is the value for Product unaccum /3 insted of sum of 3 consecutive values for Product unaccum /3.

 

Take a look. 

Graph.PNG

What should I change in the DAX to have it visualised correctly?  Please HELP

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

Hi @Anonymous,

 

Based on my test, we can take the following steps to meet your requirement.

 

1. Enter the sample data as you shared and create a Calendar table using the formula.

 

Calendar = CALENDARAUTO()

2. Create the measure to achieve your goal.

 

Measure = CALCULATE(SUM('Table'[Product A unaccum]),DATESINPERIOD('Calendar'[Date],MAX('Calendar'[Date]),-3,MONTH))/3

Capture.PNG

 

For more details, please check the pbix as attached.

 

Regards,

Frank

Community Support Team _ Frank
If this post helps, then please consider Accept it as the solution to help the others find it more quickly.

View solution in original post

2 REPLIES 2
v-frfei-msft
Community Support
Community Support

Hi @Anonymous,

 

Based on my test, we can take the following steps to meet your requirement.

 

1. Enter the sample data as you shared and create a Calendar table using the formula.

 

Calendar = CALENDARAUTO()

2. Create the measure to achieve your goal.

 

Measure = CALCULATE(SUM('Table'[Product A unaccum]),DATESINPERIOD('Calendar'[Date],MAX('Calendar'[Date]),-3,MONTH))/3

Capture.PNG

 

For more details, please check the pbix as attached.

 

Regards,

Frank

Community Support Team _ Frank
If this post helps, then please consider Accept it as the solution to help the others find it more quickly.

Hi @Anonymous,

 

Does that make sense? If so, kindly mark my answer as a solution to close the case.

 

Regards,
Frank

Community Support Team _ Frank
If this post helps, then please consider Accept it as the solution to help the others find it more quickly.

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

Check out the October 2025 Power BI update to learn about new features.

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.