Saturday, August 10, 2013

Creating Advanced Waterfall graph - Values moving from Positive to negative and vice-versa

Waterfall graph is a floating bar graph used to pictorially depict movement of any parameter or how various parts contribute to a whole parameter. For e.g. how the Headcount or profit has moved over last week, last month etc. OR various components of Net profit and so on. Given below is the example of a sample waterfall graph.

Please note that in the above graph values moves from Positive to negative and vice-versa, which makes process of making this graph little complicated. If your data is not going to cross 0 axis (i.e. not going to move from positive to negative) then please click HERE
 to see steps of making simple waterfall graph.

Steps to make waterfall graph

Step 1: Make the data table.
  1. Create the data table for base values and movements in the below mentioned format.











  2. Since the values moves from positive to negative and negative to positive, we will have to create another table linked to the above table

    • In the table above, I have used two dummy columns (cells with gray background) which are not used in graph, but are used for calculating other values 
    • Before – Running total before the current row value
      • Formula – =SUM($B$2:C2)
    • After – Running total after the current row value
      • Formula – =SUM($B$2:C3)
    • Axis Label – Self explanatory
    •  Base Value – For Start and end points
      • Formula – =IF(B2<>0,B2,0)
    • Blank – For a hidden series for adjustment
      • Formula – =IF(J2*K2>0,IF(J2*C2>0,J2,K2),0)
    •  Positive Bars – Used for depicting bars above 0 (Horizontal axis)
      • Formula – =IF(J2>0,IF(K2>J2,C2,IF(K2<0,J2,ABS(C2))),IF(K2>0,K2,0))
    • Negative Bars – Used for depicting bars below 0 (Horizontal axis)
      • Formula – =IF(J2<0,IF(K2<0,-ABS(C2),J2),IF(K2<0,K2,0))
Step 2: Make the graph
  1. Select the second data table (Only upto Negative Bar column) and Click Insert --> Column Chart --> Stacked column (this will insert stack bar graph as shown in the screenshot below)

  2. Select the legend and press delete to remove legend
  3. Select adjustment series and hide it by selecting No shape fill and no shape outline from format menu.

  4. Apply same Shape colour to Positive and Negative Bars. So that it appears as a single bar while crossing the Horizontal axis.

  5. Change the Axis label setting to Move the axis label below the negative values. Right click on Axis --> Format Axis --> Change Axis Label property to “Low”

  6. Make other formatting changes like Border, background colour, font, Gridlines etc.
Finally it should look similar to the screenshot below.




You can download the Excel file for above example from HERE.

No comments:

Post a Comment