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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Learn more

Reply
Victormar
Helper V
Helper V

Line chart with different patterns

Hello community,

 

I reach out to you all because I am trying to create a line chart having the same line with different patterns.

We have some data that we generated, and some that we get from machines, resulting in a mileage line altogether; The idea would be to simulate 1 line, where the generated data would be a dotted line and the non generated a normal line.

We have a columnt to identify wether the data is generated or not using 1 (generated) or 0.

 

I created a couple of measures, but due to filtering the lines don't overlay ( I did it using variables because first I tried without and it didn't work either, so just trying something different):

 

c_EnergyConsumptionGenerated =
var generated = FACT_Readings[EGC_IS_GENERATED] = 1
var result = IF (
generated, FACT_Readings[c_EnergyConsumption]
)
return result
 
c_EnergyConsumptionNOTGenerated =
var not_generated = FACT_Readings[EGC_IS_GENERATED] = 0
var result = IF (
not_generated, FACT_Readings[c_EnergyConsumption]
)
return result
 
c_EnergyConsumption is the main column where we calculate the Energy, then we calculate the average of it as a measure and add it to the graph. In my mind I could create these two measures to highlight the different points, but as Power BI would joint all the data points in a line chart, the result would look odd, and not overlaid:
 
Victormar_0-1662455442918.png

Red is generated, and black is not.

 

Thanks in advance for any help, have a nice day!

2 REPLIES 2
Victormar
Helper V
Helper V

Hi @Hei_aQing , the expected output would be 1 line in which some parts are dotted and others are straight, depending on the data.

My idea was to overlay the two lines to do it, but as my filter is a column "IS_FILTERED" that means it excludes some of the data points, resulting in different lines.

Didn't share any sample data because I guess it doesn't matter, sample data would serve to try it out.

 

Thanks for your time 🙂

Hei_aQing
Helper I
Helper I

HI @Victormar 

 

What is your expected output? Could you consider providing some sample data?

Helpful resources

Announcements
Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

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

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.

Top Solution Authors