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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Anonymous
Not applicable

Trend line - by weeknum - continous from 2020 to 2021

Hi all,

 

I have formatted the weeknum og my calendar table so it knows how to sort based on year. However, if I have both 2020 and 2021 in my graph, and I select "Continous" (that is the only way to make trend line, right?), then the graph looks super odd!

 

I have weeknum in axis.

 

Is this even possible?

 

wierdgraph.JPG

5 REPLIES 5
amitchandak
Super User
Super User

@Anonymous , In that case, you need to use the year week or week year column.

Or Add both Year and Week , Drill Expand, switch of concatenate labels and try (Sort on year week)

 

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
Anonymous
Not applicable

Hi @amitchandak 

 

I have a column called Year-Week (Text). I manipulated so "2021-53" is now "2020-53".

 

However, I don't seem to be able to make a trendline, in the analysis pane. Can  you show me how to do that? It works with my column "Weeknum", but I can't use that as it will just sum weeks from several years.

Anonymous
Not applicable

HI @Anonymous,

I think you can create a numeric year week instead. The continuous type seems not work properly to analyze text type values.

Calculate column expressions:

Year Week =
YEAR ( Table[Date] ) * 100
    + WEEKNUM ( Table[Date], 2 )

Regards,

Xiaoxin Sheng

Anonymous
Not applicable

Hi,

 

I tried something similar, but then it creates a huge gab beweeen the 202053 and 202101

 

week.png

Anonymous
Not applicable

Hi @Anonymous,

I think your table may not contains all the date range records, so your graph displays the smooth line on these missed date ranges. 

What type of results do you want? Can you please share some dummy data to test?

How to Get Your Question Answered Quickly 

Regards,

Xiaoxin Sheng

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

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.