cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
brkling
New Member

How to show graph interval by week

I have a spreadsheet with data that has multiple items by day. When showing one of the graphs, I want it to display the time interval on the x axis by week - how do I achieve this? Seems pretty simple but I can't figure out how to make it happen.

5 REPLIES 5
Greg_Deckler
Super User IV
Super User IV

@brkling - This is going to depend on your data. If you have a date, you could create a calculated column using WEEKNUM:

 

https://support.office.com/en-US/article/WEEKNUM-Function-DAX-e636ef36-180a-4e2d-a29b-8f549c258da0

 

And use that as your x-axis.

 

If this doesn't solve your problem, please post an example data row or partial data row.

 

 


---------------------------------------

@ me in replies or I'll lose your thread!!!

I have a NEW book! 
DAX Cookbook from Packt
Over 120 DAX Recipes!




Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




A date dimension is always the appropriate solution to this sort of problem.

Hi guys,

 

I have a similar problem, that I need to show public in a park per week but my problem is that I need a line per year.

My X should be the week numbers but need two Y, one for showing public per week of 2016 and another for 2017.

 

How would I do that?

Hi @ricardinhorio.

 

You can do this by creating two calculated measures that filter the public per year (one for 2016 and other for 2017). Something like:

 

Public2017 = FITLER(Table[ColumnW/PublicNumbers]; YEAR(Table[ColumnW/DateOfTheColectedData]) = 2017)

Public2016 = FITLER(Table[ColumnW/PublicNumbers]; YEAR(Table[ColumnW/DateOfTheColectedData]) = 2016)

 

And using this calculated measures as line values in your chart.

 

Hope it helps!

B129
Continued Contributor
Continued Contributor

 Hi brkling,

 

   look at this post made by @elliotdixon

 

http://community.powerbi.com/t5/Desktop/Display-this-week-amp-this-month-data/m-p/11207#M2459

 

..meanwhile I look for a custom solution for your problem.

 

Helpful resources

Announcements
MBAS on Demand

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

July 2021 Update 768x460.png

Check it out!

Click here to read more about the July 2021 Updates

Power Query PA Forum 768x460.png

Check it out!

Did you know that you can visit the Power Query Forum in Power BI and now Power Apps

Urdu Hindi D365 Bootcamp 768x460.png

Urdu Hindi D365 Bootcamp

Dont miss our very own April Dunnam’s The Developer Guide to the Galaxy! Find out what the Power Platform has to offer for the traditional developer.

Top Solution Authors
Top Kudoed Authors