Conditional Format Bar Chart

Will85

Active Member
Joined
Apr 26, 2012
Messages
254
Office Version
  1. 365
Platform
  1. Windows
My data is very simple. I have Fav(Unfav) variances by department.

I want to use a bar chart, however I want to display the absolute value of the data, but format the departments that were unfavorable a different color.

I don't like (I don't have enough space) how the negative departments go one way, and the positive another. I want them all to go the same direction, however differentiate the fav(unfav) by color.

I thought about maybe adding a 1 or zero as another data set for each department that would conditionally change if the variance changes, but not sure how I could incorporate that into the chart to drive the formatting.
 

Excel Facts

Excel Joke
Why can't spreadsheets drive cars? They crash too often!
Let's say you have a table like this
Original table
Name Depvalue
Dep_1515,60
Dep_2-311,59
Dep_3389,23
Dep_4-321,38
Dep_5374,94
Dep_6444,51

In order to display positive and negative departments in different colors on one axis, you need to create a separate table like this
Data for plotting the chart
positivenegative
515,600,00
0,00311,59
389,230,00
0,00-321,38
374,940,00
444,510,00

The point of this table is that in the first column we display data for positive departments, and for negative ones we put "0", in the second column we do the opposite, we write data for negative departments, and for positive ones we put "0". After that we build a diagram based on this table, only we take the names of the departments from the first one.
As a result, you will get a histogram like this with different colors for positive and negative departments.
 
Upvote 0

Forum statistics

Threads
1,223,855
Messages
6,175,023
Members
452,603
Latest member
bendarasdavide

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top