Ask Your Question
2

How can a color condition be applied in a column chart in Power BI with upper and lower limits?

asked 2023-05-04 14:27:13 +0000

david gravatar image

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
1

answered 2023-05-04 14:45:02 +0000

scrum gravatar image

To apply a color condition with upper and lower limits in a column chart in Power BI, follow these steps:

  1. Select the column chart you want to modify.
  2. Click on the Data view and add a new column to your dataset that reflects the color condition you want to apply. For example, if you want to color a column green if the value is above 80, red if it's below 60, and yellow if it's between 60 and 80, create a column with the following formula:

    =IF(value > 80, "green", IF(value < 60, "red", "yellow"))

  3. Go back to the Visualizations tab and select the column chart.

  4. Click on the three dots (...) next to the Values section of the Visualizations pane, and select "Conditional formatting".
  5. In the "Based on field" dropdown menu, select the column you created in step 2.
  6. Under "Color scale", select "Custom diverging".
  7. Set the minimum and maximum values to 0 and 100, respectively.
  8. Set the colors for the minimum, mid, and maximum values. For example, you could set the minimum value to red, the mid value to yellow, and the maximum value to green.
  9. Adjust any other settings you want, such as the legend, and click "OK".

Your column chart will now show the colors you specified based on the values in the column you created. Values above 80 will be green, values below 60 will be red, and values between 60 and 80 will be yellow.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account. This space is reserved only for answers. If you would like to engage in a discussion, please instead post a comment under the question or an answer that you would like to discuss

Add Answer


Question Tools

Stats

Asked: 2023-05-04 14:27:13 +0000

Seen: 10 times

Last updated: May 04 '23