Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
Hi, im trying to add a 3 month moving average line. I would like an average line for May to July followed by average for aug - oct.
Solved! Go to Solution.
Hi @Ken237 ,
May I ask if this is the expected output you are looking for? Based on your description, I calculated the averages for May-July and August-October separately and displayed the visuals on a line chart.
Please create a new Measure, and drag the new Measure to the Y-axis.
Measure2 =
SWITCH(
TRUE (),
SELECTEDVALUE ( 'Tabelle2'[Month] ) IN { "May", "June", "July" },
CALCULATE (
AVERAGE ( 'Tabelle2'[Resolution Time] ),
'Tabelle2'[Month] IN { "May", "June", "July" },
ALL('Tabelle2'[Month],'Tabelle2'[Index])
)
,
SELECTEDVALUE ( 'Tabelle2'[Month] ) IN { "August", "September", "October" },
CALCULATE (
AVERAGE ( 'Tabelle2'[Resolution Time] ),
'Tabelle2'[Month] IN { "August", "September", "October" },
ALL('Tabelle2'[Month],'Tabelle2'[Index])
)
)
If this doesn’t work, could you please share some sample data without sensitive information and expected output.
How to provide sample data in the Power BI Forum - Microsoft Fabric Community
Best Regards,
Yang
Community Support Team
If there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly.
If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!
How to get your questions answered quickly -- How to provide sample data in the Power BI Forum
Hi @Ken237 ,
May I ask if this is the expected output you are looking for? Based on your description, I calculated the averages for May-July and August-October separately and displayed the visuals on a line chart.
Please create a new Measure, and drag the new Measure to the Y-axis.
Measure2 =
SWITCH(
TRUE (),
SELECTEDVALUE ( 'Tabelle2'[Month] ) IN { "May", "June", "July" },
CALCULATE (
AVERAGE ( 'Tabelle2'[Resolution Time] ),
'Tabelle2'[Month] IN { "May", "June", "July" },
ALL('Tabelle2'[Month],'Tabelle2'[Index])
)
,
SELECTEDVALUE ( 'Tabelle2'[Month] ) IN { "August", "September", "October" },
CALCULATE (
AVERAGE ( 'Tabelle2'[Resolution Time] ),
'Tabelle2'[Month] IN { "August", "September", "October" },
ALL('Tabelle2'[Month],'Tabelle2'[Index])
)
)
If this doesn’t work, could you please share some sample data without sensitive information and expected output.
How to provide sample data in the Power BI Forum - Microsoft Fabric Community
Best Regards,
Yang
Community Support Team
If there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly.
If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!
How to get your questions answered quickly -- How to provide sample data in the Power BI Forum
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
| User | Count |
|---|---|
| 39 | |
| 38 | |
| 38 | |
| 28 | |
| 27 |
| User | Count |
|---|---|
| 124 | |
| 88 | |
| 73 | |
| 66 | |
| 65 |