# VICNISS Hospital Acquired Infection Surveillance Coordinating Centre

10 Wreckyn Street North Melbourne VIC 3051 Tel: 03 9342 2605 Fax: 03 9342 2633 email: vicniss@mh.org.au web: www.vicniss.org.au

How to Create Histograms with 95% Confidence Intervals in MS Excel
The 95% CI indicates that the true rate lies somewhere between these intervals. To represent these graphically, a number of steps must be undertaken prior to creating the chart. 1. Your data will look like this in an excel spreadsheet:
Risk Index 0 1 2 3 Number of SSI 11 43 32 21 Total Number of procedures 485 832 456 207

Rate 2.3 5.2 7.0 10.1

95% CI 1.1-4.0 3.8-6.9 4.8-9.8 6.4-15.1

(there may also be a NULL row in some instances).

2. Firstly, create two new columns which will indicate the difference between the rate and the highest range of the 95% CI and the lowest range of the 95% CI.
Risk Index 0 1 2 3 Number of SSI 11 43 32 21 Total Number of procedures 485 832 456 207 Upper 95 Lower 95

Rate 2.3 5.2 7.0 10.1

95% CI 1.1-4.0 3.8-6.9 4.8-9.8 6.4-15.1

For Risk Index 0, subtract the rate (2.3) from the upper 95%CI (4.0). This can be calculated using a formula in the cell or calculated manually i.e. 4.0-2.3=1.7. Insert 1.7 into the Upper 95 column;
Risk Index 0 1 2 3 Number of SSI 11 43 32 21 Total Number of procedures 485 832 456 207 Upper 95 1.7 Lower 95

Rate 2.3 5.2 7.0 10.1

95% CI 1.1-4.0 3.8-6.9 4.8-9.8 6.4-15.1

9 4.8-9.e.8 6.2 into the Lower 95% CI column.1 95% CI 1.7 Rate 2.0 10.1-4.1=1.4 2.8-9.2 1. put a 0 (zero) as the upper and lower 95.0 3.VICNISS – Creating Histograms with 95% Confidence Intervals To calculate the difference between the rate and the Lower 95%CI. Insert 1.3 5. So that Excel can read the data correctly.1 If the 95% CI is reported as n/a.4-15.8-6.0 Lower 95 1.1 4.1 95% CI 1.4 2.8 6.2 3.0 Lower 95 1.8 6. Risk Index RI 0 RI 1 RI 2 RI 3 Number of SSI 11 43 32 21 Total Number of procedures 485 832 456 207 Upper 95 1.4-15. Risk Index 0 1 2 3 Number of SSI 11 43 32 21 Total Number of procedures 485 832 456 207 Upper 95 1.2 Rate 2.8-6.9 4. Risk Index 0 1 2 3 Number of SSI 11 43 32 21 Total Number of procedures 485 832 456 207 Upper 95 1.7 Rate 2.2 1.7 Lower 95 1. 24 July 2003 Page 2 of 11 .2 3.2 7.7 1. 3.3-1.8-9.8 5. Repeat these steps for the 95% CI for Risk Index 1.2 7.9 4.0 3.2. 2 and 3 rows.1 95% CI 1.1-4. subtract the Lower 95%Ci from the rate i.4-15.1-4. insert ‘RI’ into the Risk Index column next to the numbers.3 5.0 3.0 10.2 7.7 2.1 (for NULL.8-6. insert “RI NULL”) You are now ready to start creating the chart.7 1.7 2.8 5.3 5.0 10. 2.

Continue to hold down CTRL. 24 July 2003 Page 3 of 11 . select the Risk Index column.VICNISS – Creating Histograms with 95% Confidence Intervals 5. Whilst holding down CTRL. and select the Rate column. (Select by clicking in the cell and dragging over cells you wish to select) 6.

VICNISS – Creating Histograms with 95% Confidence Intervals 7. 24 July 2003 Page 4 of 11 . The “Chart Wizard” will then appear. labeling and formatting as desired. click on the “Chart Wizard” icon from the menu. 8. Once selected. Follow the instructions in the Wizard.

your chart should look like this. 10. 24 July 2003 Page 5 of 11 .VICNISS – Creating Histograms with 95% Confidence Intervals 9. Once completed. To create the 95% CI bars. double click in the middle of any of the histogram bars.

Select the “Y Error Bars” tab 24 July 2003 Page 6 of 11 . 12.VICNISS – Creating Histograms with 95% Confidence Intervals 11. The “Format Data Series” window will appear.

Select the Custom button. Click ‘Both’ in Display box: 14.VICNISS – Creating Histograms with 95% Confidence Intervals 13. 24 July 2003 Page 7 of 11 . and click in the “+” bar.

16. With the cursor flashing in the “+” bar.VICNISS – Creating Histograms with 95% Confidence Intervals 15. 24 July 2003 Page 8 of 11 . Now select the data in the Upper 95 column. click on the spreadsheet tab where the data is stored.

and the cell range will appear in the “-“ bar.VICNISS – Creating Histograms with 95% Confidence Intervals 17. The cell range will now be displayed in the “+” bar of the “Format Data Series” window. 18. Repeat this for the – bar. 24 July 2003 Page 9 of 11 . Click in the “-“ bar and select the data in the Lower 95 column.

Now click “OK”.VICNISS – Creating Histograms with 95% Confidence Intervals 19. The histogram will now appear with the 95% CI bars evident. 20. 24 July 2003 Page 10 of 11 .

double click on any one of them as alter appearance as desired. Done!!! 24 July 2003 Page 11 of 11 . To format these bars. 22.VICNISS – Creating Histograms with 95% Confidence Intervals 21.