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_10© Springer Science+Business Media B.V. 2011

10. Z-Test 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
Two groups of patients are assessed for being sleepy through the day. We wish to estimate whether group 1 is more sleepy than group 2. The underneath cross-tab gives the data.
Two groups of patients are assessed for being sleepy through the day. We wish to estimate whether group 1 is more sleepy than group 2. The underneath cross-tab gives the data.
 
Sleepiness
No sleepiness
Treatment 1 (group 1)
5 (a)
10 (b)
Treatment 2 (group 2)
9 (c)
 6 (d)
 $$\begin{array}{lll}{\rm z}&=\frac{\hbox {difference between proportions of sleepers per group (d)}}{\hbox{pooled standard error difference}}\end{array}$$
 $$\rm{z}=\frac{\text{d}}{\hbox{pooled SE}}=\frac{(9/15-5/15)}{\sqrt{{\text{(SE}}_{1}^{2}+{\text{SE}}_{2}^{2})}}$$
 $$\rm{SE}_{1}(or SEM_1)=\frac{\surd{P_1(1-p_1)}}{n_1}{\rm Where P_1 = 5/15 ets.......,}$$
z  =  1.45, not statistically significant from zero, because for a p  <  0.05 a
z-value of at least 1.96 is required. This means that no significant difference between the two groups is observed. The p-value of the z-test can be obtained by using the bottom row of the t-table from page 21.
Note:
For the z-test a normal distribution approach can be used. The t-distributions are usually a bit wider than the normal distributions, and therefore, adjustment for study size using degrees of freedom (left column of the t-table) is required. With a large study size the t-distribution is equal to the normal distribution, and the t-values are equal to the z-values. They are given in the bottom row of the t-table.
Note:
A single group z-test is also possible. For example in ten patients we have four responders. We question whether four responders is significantly more than zero responders.
 $$ {\rm Z}={\rm proportion} / ({\rm its SE}) $$
 $$ {\rm SE}=\surd[(\frac{4}{10}\times(1-\frac{4}{10}))/{\rm n}] $$
 $$ \surd(\frac{0.24}{10})$$
 $$ {\rm{z}}=\frac{0.4}{\surd(\frac{0.24}{10})}$$
 $$ \rm{z}=\frac{0.4}{0.1549}$$
 $$ \rm{z}=2.582$$
According to the bottom row of the t-table from page 21 the p-value is  < 0.01. The proportion of 0.4 is, thus, significantly larger than a proportion of 0.0.