Skip to main content
. 2014 Feb;35(1):37–61.

Table 3.

Anion gap Monte Carlo simulation. Excel spreadsheet representation showing 10,000 anion gap trials (column H) for the quantity values and uncertainty estimates described in Table 2.

A B C D E F G H


1 Input quantities Formula Output quantity


2 Na+ mmol/L K+ mmol/L Cl mmol/L HCO3 mmol/L AG mmol/L
3 Value 140 4.5 105 25 AG = Na+ + K+ − Cl − HCO3 14.5
4 Uncertainty 1.2 0.10 1.5 1.2
5
6 Trial results
7 Trial # AG
8 1 140.12 4.53 105.99 24.16 AG = Na+ + K+ − Cl − HCO3 14.50
9 2 140.70 4.39 105.44 24.38 15.27
10 3 140.16 4.52 104.46 25.70 14.51
11 4 140.52 4.59 104.92 24.40 15.79
12 5 140.94 4.36 106.54 26.09 12.67
13 6 139.05 4.64 105.54 25.18 12.97
14 7 139.51 4.58 104.02 24.92 15.15
15 8 138.01 4.55 105.05 25.14 12.38
16 9 139.94 4.60 102.73 24.50 17.31
17 10 140.58 4.47 108.03 23.62 13.39
10007 10000 142.73 4.49 107.31 24.97 AG = Na+ + K+ − Cl − HCO3 14.94
The simulated anion gap (AG) values in column H are derived from the input variables in columns B, C, D and E, rows 8 to 10007:
  • Column B rows 8 to 10007; (NORMINV(RAND(),$B$3,$B$4)),
  • Column C rows 8 to 10007; (NORMINV(RAND(),$C$3,$C$4)),
  • Column D rows 8 to 10007; (NORMINV(RAND(),$D$3,$D$4)),
  • Column E rows 8 to 10007; (NORMINV(RAND(),$E$3,$E$4)).
(The arrows (↓ and →) play no part in the calculations; they have been added to the table for illustrative purposes only.)