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

Don't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.

Reply
PSB
Helper III
Helper III

rolling 7 days Median trend (Power Query)

I have data with Date and Data field. I need rolling 7 days median chart.

for each day, I need what was past 7 days median.  X-Axix (date), Y-Axis (Median value for past 7 days)

there are multiple values for each day.

DateData
1/1/20210.1
1/1/20210.5
1/1/20210.9
1/2/20210.5
1/2/20210.6
1/2/20210.6
1/3/20210.1
1/3/20210.9
1/3/20211.8
1/4/20212.8
1/5/20213.8
1/6/20214.8
1/7/20215.8
1/8/20216.8
1/9/20217.8
1/10/20218.8
1/11/20219.8
1/12/202110.8
1/13/202111.8
1/14/20210.6
1/15/20210.1
1/16/20210.9
1/17/20211.8
1/18/20212.8
1/19/202117.8
1/20/202118.8
1/21/202119.8
1/22/20210.6
1/23/20210.1
1/24/20210.9
1/25/20211.8
1/26/20212.8
1/27/202125.8
1/28/202126.8
1 ACCEPTED SOLUTION

Hi,

PBI file attached.

Hope this helps.

Ashish_Mathur_0-1701398933308.png

 


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

View solution in original post

5 REPLIES 5
Ashish_Mathur
Super User
Super User

Hi,

This shoud typically be done with a measure (not in Power Query).  Would you be OK with that?


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

Yes, that will work too. Would you please share pbix file with solution?

 Thanks

Hi,

PBI file attached.

Hope this helps.

Ashish_Mathur_0-1701398933308.png

 


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

Really appreciate your help. This solution worked for me.

You are welcome.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

Jan25PBI_Carousel

Power BI Monthly Update - January 2025

Check out the January 2025 Power BI update to learn about new features in Reporting, Modeling, and Data Connectivity.

Jan NL Carousel

Fabric Community Update - January 2025

Find out what's new and trending in the Fabric community.