Fast Ideas: Line Chart and Space Chart Conditional Formatting in Energy BI

Date:


Line Chart and Area Chart Conditional Formatting in Power BI

On this submit I present you a really fast trick to format Line Chart and Space Chart conditionally in Energy BI. As it is a “Fast Tip” I’m going to maintain this submit actually quick.

One in all my clients requested me to point out time collection in line charts and space charts. However she need’s it to be conditionally formatted based mostly on the typical worth over time. Let’s maintain it easy, she needs to point out “Gross sales by 12 months Month” in line chart, however, spotlight the info factors which are beneath “Common Gross sales per 12 months Month”. As chances are you’ll know, we at the moment shouldn’t have the luxurious of formatting line charts and space charts. However wait, this submit is all about that. Let’s dig into it.

From the above state of affairs, you maybe already guessed that we have to create a measure which defines the color based mostly on “Common Gross sales per 12 months Month” to have the ability to format the chart conditionally. If any information level is beneath the “Common Gross sales per 12 months Month” then we spotlight it in Orange, whether it is above the “Common Gross sales per 12 months Month” then we keep on with the default color.

Let’s do it.

It’s very easy to do, simply comply with the steps beneath:

  • Put a column chart on the canvas
  • Add the “12 months Month” column to the column chart’s Axis
  • Add the measure to the column chart’s Values
  • Format the column chart conditionally, extra on this later
  • Flip the column chart to line chart or space chart by choosing line/space chart from Visuals pane

That’s it. Let’s look into extra particulars of the answer.

This methodology completely help conditional formatting, however it’s a must to take note of the sector you’re utilizing on X Axis. You must have steady values on X axis, subsequently the values should be both a “quantity” or “date” (datetime). What you usually see in values of “12 months Month” column is a string like “2019 Jan”, “2019-Jan” or “2019 – Jan”, proper? So that you simply have to convert “2019 Jan” or “2019-Jan” to “date” information sort both in Energy Question or through the “Column Instruments” from the ribbon. If we don’t convert string to this point and put the “12 months Month” on X Axis, now we have “Categorical” sort on X Axis and that’s NOT what we would like.

Have you ever used this methodology? Have you learnt a greater methodology to do the identical factor? Please share your ideas within the feedback part beneath.

Obtain the PBIX file from right here.

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Share post:

Subscribe

spot_imgspot_img

Popular

More like this
Related

Webinar Recap: 2025: A Altering ESG Panorama

The purpose of this webinar was...

Find out how to Select the Finest WordPress Internet hosting for Builders

 As a developer, you require greater than easy...

How outsourcing helps insurance coverage companies and their shoppers

Insurance coverage executives could possibly be excused for...

8 issues it is best to by no means sacrifice for somebody (even should you love them)

Life is a good looking puzzle, filled with...