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

Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!

Reply
OneWithQuestion
Post Prodigy
Post Prodigy

Line chart with shaded area?

I would like to make a chart like this:

LineWithShadedAreaExample.PNG

 

Where there is a shaded goal area, and then a line.

 

The goal area is NOT hard coded, it needs to be set be mapped against a measure.  In the above example the goal line happend to be static, but it could change over time.

 

Any suggestions?  Thanks!

 

 

EDIT:

This is the closest I could come, but I would really like to be able to format the shading to drop that from the second measure:

ShadedAreaChart.png

 

That redish pink area would work better as a LINE not a shaded area.

9 REPLIES 9
ashako88
Frequent Visitor

ashako88_0-1638825500847.png

 In case someone is still looking for this option, it's one of the updated versions in 2021 (not sure which one). Allows you to pick which line to shade under.

 

@OneWithQuestion This would be a good formatting option to have in the Area Chart for sure... to be able disable some of the shades in the lines to use a goal line measure. Other than your idea below, the only other thing I could come up with is to use a "line and stacked column chart" - but this produces gaps and is visually distracting. I tried a bunch of different overlays and tricks, but the x-axis isn't constant and it won't align well in overlap correctly as the goal changes. 😞

linegoal.JPG


Looking for more Power BI tips, tricks & tools? Check out PowerBI.tips the site I co-own with Mike Carlo. Also, if you are near SE WI? Join our PUG Milwaukee Brew City PUG

Yeah, I tried that too and ran into issues with bar gaps that I know would really distract and confuse the users so... I just gave up on that 😞

 

I did post a question about anyway to hide gap though.

Hi @OneWithQuestion,

 

I have tested it on my local environment using the sample data below.
Capture.PNGCapture1.PNG

We can get the expected result like below.

 

Capture2.PNG

 

Regards,

Charlie Liao

Hi @v-caliao-msft,

 

Thanks for this solution. How did you get the Difference series to start at 1000?

 

Thanks much !

@v-caliao-msft Don't worry - got it ! Stacked area-chart.... 

Sadly, that still shows a shaded area under the line.

 

Ideally one would be a line and the other would be a shaded area (or column bar chart with adjusted gap width)

Hi @OneWithQuestion,

 

Currently, this the closest workaround we can achieve in Power BI, if this is not what you want, you can create a custom visual to achieve it if you have rich experience in coding.

 

Regards,

Charlie Liao

Helpful resources

Announcements
April AMA free

Microsoft Fabric AMA Livestream

Join us Tuesday, April 09, 9:00 – 10:00 AM PST for a live, expert-led Q&A session on all things Microsoft Fabric!

March Fabric Community Update

Fabric Community Update - March 2024

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

Top Solution Authors
Top Kudoed Authors