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

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
Betty888
Helper II
Helper II

Line chart with different lines per year

Dear all, 

I have a dataset that looks as below : 

CompanyYearSales 
1201860
1201930
1202035
2201825
2201963
2202035
3201898
3201996
3202022
4201865
4201989
4202075
5201849
5201912
5202032

 

and I want to create a graph as I tried to draw below 🙂 

Betty888_0-1681529098753.png

1 line per year and X axis = Company name / Y axis = sales (my response variable).

Can you please suggest any way to do this in Power Bi please 🙏

Thank you in advance for your help ! 

 

1 ACCEPTED SOLUTION
Ritaf1983
Super User
Super User

Hi @Betty888  

In order to get to the graph you drew, follow these steps:

1. Choose line chart
2. Put your parametrs like on pict :

Ritaf1983_0-1681531962119.png

3. Set up a series labels 

Ritaf1983_1-1681532033898.png

It is important to note that such a logical comparison is problematic.
A trend line shows the evolution of an index over time.
It is recommended to make an X-axis as a time axis in order to compare long-term trends between companies.
For each company, there is a representative line.
As you have several lines that collide, it is better to split it into smaller graphs so you don't create cognitive load
Using "small multiples"
As shown in the picture (with setup a right format and design)

Ritaf1983_0-1681532673627.png

 

Link to sampke file with both options here 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Regards,
Rita Fainshtein | Microsoft MVP
https://www.linkedin.com/in/rita-fainshtein/
Blog : https://www.madeiradata.com/profile/ritaf/profile

View solution in original post

5 REPLIES 5
Ritaf1983
Super User
Super User

Hi @Betty888  

In order to get to the graph you drew, follow these steps:

1. Choose line chart
2. Put your parametrs like on pict :

Ritaf1983_0-1681531962119.png

3. Set up a series labels 

Ritaf1983_1-1681532033898.png

It is important to note that such a logical comparison is problematic.
A trend line shows the evolution of an index over time.
It is recommended to make an X-axis as a time axis in order to compare long-term trends between companies.
For each company, there is a representative line.
As you have several lines that collide, it is better to split it into smaller graphs so you don't create cognitive load
Using "small multiples"
As shown in the picture (with setup a right format and design)

Ritaf1983_0-1681532673627.png

 

Link to sampke file with both options here 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Regards,
Rita Fainshtein | Microsoft MVP
https://www.linkedin.com/in/rita-fainshtein/
Blog : https://www.madeiradata.com/profile/ritaf/profile
Anonymous
Not applicable

hello thank you for explaine how to do it
I have a question if anyone can help me 
i have a line chart 

badiss_0-1690474714174.png

I want to calculate the difference between each two points of the same date ?

 

Hi @Ritaf1983 ,

Very many thanks for your reply ! it was really helpful !!!!

amitchandak
Super User
Super User

@Betty888 , You can have a year on legend

 

amitchandak_0-1681531558303.png

 

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

Hi @amitchandak ,

Many thanks for your reply ! 

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

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

August 2025 community update carousel

Fabric Community Update - August 2025

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

Top Solution Authors