Ton J. Cleophas and Aeilko H. ZwindermanStatistical Analysis of Clinical Data on a Pocket CalculatorStatistics on a Pocket Calculator10.1007/978-94-007-1211-9_11© Springer Science+Business Media B.V. 2011

11. Chi-Square Tests for Cross-Tabs

Ton J. Cleophas1, 2   and Aeilko H. Zwinderman2, 3  
(1)
Department of Medicine, Albert Schweitzer Hospital, Dordrecht, The Netherlands
(2)
European College of Pharmaceutical Medicine, Lyon, France
(3)
Department of Epidemiology and Biostatistics, Academic Medical Center, Amsterdam, The Netherlands
 
 
Ton J. Cleophas (Corresponding author)
 
Aeilko H. Zwinderman
Abstract
The underneath table shows two separate groups with patients assessed for suffering from sleepiness through the day. We wish to know whether there is a significant difference between the proportions of subjects being sleepy.

First Example Cross-Tab

The underneath table shows two separate groups with patients assessed for suffering from sleepiness through the day. We wish to know whether there is a significant difference between the proportions of subjects being sleepy.
 
Sleepiness
No sleepiness
 
Group 1
 5 (a)
10 (b)
15 (a  +  b)
Group 2
 9 (c)
 6 (d)
15 (c  +  d)
 
14 (a  +  c)
16 (b  +  d)
30 (a  +  b  +  c  +  d)
The chi-square pocket calculator method is used for testing these data.
 $$\begin{array}{l}{\chi }^{2}=\frac{{(\text{ad}-\text{bc})}^{2}(\text{a}+\text{b}+\text{c}+\text{d})}{(\text{a}+\text{b})(\text{c}+\text{d})(\text{b}+\text{d})(\text{a}+\text{c})}=\frac{(30-90)^{2}(30)}{\text{15}\times \text{15}\times \text{16}\times \text{14}}=\frac{\text{3,600}\times \text{30}}{\text{15}\times \text{15}\times \text{16}\times \text{14}}\\ \text{}=\frac{108.000}{50.400}=2.143\end{array}$$
The chi-square value equals 2.143. The chi-square table can tell us whether or not the difference between the groups is significant. See next page for the procedure to be followed.

Chi-Square Table (χ2-Table)

The underneath chi-square table gives columns and rows: the upper row gives the p-values. The first column gives the degrees of freedom which is here largely in agreement with the numbers of cells in a cross-tab. The simplest cross-tab has 4 cells, which means 2  ×  2  =  4 cells. The table has been constructed such that we have here (2–1)  ×  (2–1)  =  1 degree of freedom. Look at the row with 1 degree of freedom: a chi-square value of 2.143 is left from 2.706. Now look from here right up at the upper row. The corresponding p-value is larger than 0.1 (10%). There is, thus, no significant difference in sleepiness between the two groups. The small difference observed is due to the play of chance.
Chi-squared distribution
 
Two-tailed P-value
 
df
0.10
0.05
0.01
0.001
   
1
2.706
3.841
6.635
10.827
2
4.605
5.991
9.210
13.815
3
6.251
7.815
11.345
16.266
4
7.779
9.488
13.277
18.466
5
9.236
11.070
15.086
20.515
6
10.645
12.592
16.812
22.457
7
12.017
14.067
18.475
24.321
8
13.362
15.507
20.090
26.124
9
14.684
16.919
21.666
27.877
10
15.987
18.307
23.209
29.588
11
17.275
19.675
24.725
31.264
12
18.549
21.026
26.217
32.909
13
19.812
22.362
27.688
34.527
14
21.064
23.685
29.141
36.124
15
22.307
24.996
30.578
37.698
16
23.542
26.296
32.000
39.252
17
24.769
27.587
33.409
40.791
18
25.989
28.869
34.805
42.312
19
27.204
30.144
36.191
43.819
20
28.412
31.410
37.566
45.314
21
29.615
32.671
38.932
46.796
22
30.813
33.924
40.289
48.268
23
32.007
35.172
41.638
49.728
24
33.196
36.415
42.980
51.179
25
34.382
37.652
44.314
52.619
26
35.563
38.885
45.642
54.051
27
36.741
40.113
46.963
55.475
28
37.916
41.337
48.278
56.892
29
39.087
42.557
49.588
58.301
30
40.256
43.773
50.892
59.702
40
51.805
55.758
63.691
73.403
50
63.167
67.505
76.154
86.660
60
74.397
79.082
88.379
99.608
70
85.527
90.531
100.43
112.32
80
96.578
101.88
112.33
124.84
90
107.57
113.15
124.12
137.21
100
118.50
124.34
135.81
149.45

Second Example Cross-Tab

Two partnerships of internists have the intention to associate. However, in one of the two a considerable number of internists has suffered from a burn-out.
 
Burn out
No burn out
 
Partnership 1
3 (a)
 7 (b)
10 (a  +  b)
Partnership 2
0 (c)
10 (d)
10 (c  +  d)
 
3 (a  +  c)
17 (b  +  d)
20 (a  +  b+  c+  d)
 $${\chi }^{2}=\frac{{(\text{ad}-\text{bc})}^{2}(\text{a}+\text{b}+\text{c}+\text{d})}{(\text{a}+\text{b})(\text{c}+\text{d})(\text{b}+\text{d})(\text{a}+\text{c})}=\frac{(30-0)^{2}(20)}{\text{10}\times \text{10}\times \text{17}\times \text{3}}=\frac{\text{900}\times \text{20}}{\mathrm{........}}=3.529$$
According to the chi-square table of the previous page a p-value is found of  <0.10.
This means that no significant difference is found, but a p-value between 0.05 and 0.10 is looked upon as a trend to significance. The difference may be due to some avoidable or unavoidable cause. We should add here that values in a cell lower than 5 is considered slightly inappropriate according to some, and another test like the log likelihood ratio test (Chap. 13) is more safe.
A216868_1_En_11_Figa_HTML.gif

Example for Practicing 1

Example
2 × 2 table
Events
No events
 
 
Group 1
15 (a)
20 (b)
35 (a  +  b)
 
Group 2
15 (c)
 5 (d)
20 (c  +  d)
   
30 (a  +  c)
25 (b  +  d)
55 (a  +  b  +  c  +  d)
Pocket calculator
 $$\frac{{(\text{ad}-\text{bc})}^{2}\text(\text{a}+\text{b}+\text{c}+\text{d})}{(\text{a}+\text{b})\text(\text{c}+\text{d})\text(\text{b}+\text{d})\text(\text{a}+\text{c})}=\, \, \,\,\,\,\,\,\,\,\,\,\,\,\text{p}=\mathrm{...}$$

Example for Practicing 2

Another example
2  ×  2 table
Events
No events
 
 
Group 1
16 (a )
26 (b)
42 (a  +  b)
 
Group 2
 5 (c)
30 (d)
35 (c  +  d)
   
21 (a  +  c)
56 (b  +  d)
77 (a  +  b  +c  +  d)
Pocket calculator
 $$ \frac{{(\text{ad}-\text{bc})}^{2}\text(\text{a}+\text{b}+\text{c}+\text{d})}{(\text{a}+\text{b})\text(\text{c}+\text{d})\text(\text{b}+\text{d})\text(\text{a}+\text{c})}=\,\,\,\,\,\,\,\,\,\,\,\,\,\,\text{p}=\mathrm{...}$$