© Springer International Publishing Switzerland 2016
Ton J. Cleophas and Aeilko H. ZwindermanSPSS for Starters and 2nd Levelers10.1007/978-3-319-20600-4_50

50. Monte Carlo Tests for Binary Data (139 Physicians and 55 Patients)

Ton J. Cleophas1, 2  and Aeilko H. Zwinderman2, 3
(1)
Department Medicine, Albert Schweitzer Hospital, Dordrecht, The Netherlands
(2)
European College Pharmaceutical Medicine, Lyon, France
(3)
Department Biostatistics, Academic Medical Center, Amsterdam, The Netherlands
 

1 General Purpose

Monte Carlo methods allows you to examine complex data more easily than advanced mathematics like integrals and matrix algebra. It uses random numbers from your own study rather than assumed Gaussian curves. Monte Carlo analyses of continuous outcome data are reviewed in the Chap. 27. In this chapter we will review Monte Carlo analyses for paired and unpaired binary data.

2 Schematic Overview of Type of Data File, Paired Data

A211753_2_En_50_Figa_HTML.gif

3 Primary Scientific Question, Paired Data

For paired data McNemar tests is adequate (Chap. 41). Does Monte Carlo analysis of the same data provide better sensitivity of testing.

4 Data Example, Paired Data

In a study of 139 general practitioners the primary scientific question was, is there a significant difference between the numbers of practitioners who give lifestyle advise in the periods before and after postgraduate education.
Lifestyle advise-1
Lifestyle advise-2
Age
,00
,00
89,00
,00
,00
78,00
,00
,00
79,00
,00
,00
76,00
,00
,00
87,00
,00
,00
84,00
,00
,00
84,00
,00
,00
69,00
,00
,00
77,00
,00
,00
79,00
0 = no, 1 = yes
The first 10 physicians of the data file is given above. The entire data file is in extras.springer.com, and is entitled “chapter41pairedbinary”.

5 Analysis: Monte Carlo, Paired Data

For analysis the statistical model Two Related Samples in the module Nonparametric Tests is required.
Command:
  • Analyze....Nonparametric....Two Related Samples....Test Pairs....Pair 1....Variable 1: enter lifestyleadvise after....Variable 2: enter lifestytleadvise before....mark McNemar....click Exact....click Monte Carlo....set Confidence Intervals: 99 %....set Number of Samples: 10000....click Continue…click OK.
lifestyleadvise before & lifestyleadvise after
Lifestyleadvise before
Lifestyleadvise after
,00
1,00
,00
65
28
1,00
12
34
Test Statisticsa,b
 
Lifestyle after 1 year – lifestyle
Z
   
−2,530c
Asymp. Sig. (2-tailed)
   
,011
Monte Carlo Sig. (2-tailed)
Sig.
 
,016
 
95 % Confidence Interval
Lower bound
,008
   
Upper bound
,024
Monte Carlo Sig. (1-tailed)
 
Sig.
,010
 
95 % Confidence Interval
Lower bound
,004
   
Upper bound
,016
aWilcoxon Signed Ranks Test
bBased on 1000 sampled tables with starting seed 2000000
cBased on negative ranks
The above table is in the output. The two sided level of statistical significance is 0,016. This is slightly smaller than the p-value produced by the nonparametric Mc Nemar test (Chap. 41), p = 0,018, and, so, a slightly better fit for the data was obtained by the Monte Carlo method.

6 Schematic Overview of Type of Data File, Unpaired Data

A211753_2_En_50_Figb_HTML.gif

7 Primary Scientific Question, Unpaired Data

For unpaired binary data Pearson chi-square is adequate. Is Monte Carlo testing better sensitive for the analysis of such data.

8 Data Example, Unpaired Data

In 55 patients the effect of the hospital department on the risk of falling out of bed was assessed. The entire data file is in “chapter35unpairedbinary”, and is in extras.springer.com.
Fall out of bed
Department
1 = yes, 0 = no
0 = surgery, 1 = internal medicine
1,00
,00
1,00
,00
1,00
,00
1,00
,00
1,00
,00
1,00
,00
1,00
,00
1,00
,00
1,00
,00
1,00
,00

9 Data Analysis, Monte Carlo, Unpaired Data

For analysis the statistical model Chi-square in the module Nonparametric Tests is required.
Command:
  • Analyze….Nonparametric tests….Chi-square….Test variable list: enter department and fall out of bed….click “Exact”….Click: Monte Carlo method….set Confidence Interval, e.g., 99 %, and set Numbers of Samples, e.g., 10 000….click Continue….OK.
Test statistics
     
Department
Fall out of bed
Chi-Square
   
4,091a
,455a
df
   
1
1
Asymp.Sig.
   
,043
,500
Monte Carlo Sig.
Sig.
 
,064b
,595b
 
99 % confidence interval
Lower bound
,057
,582
   
Upper bound
,070
,608
a0 cells (,0 %) have expected frequencies less than 5. The minimum expected cell frequency is 27,5
bBased on 10000 sampled tables with starting seed 926214481
The Monte Carlo analysis provided a larger p -value than did the Pearson chi-square test (Chap. 35) with p-values of respectively 0,064 and 0,021.

10 Conclusion

Monte Carlo methods allow you to examine complex data more easily and more rapidly than advanced mathematics like integrals and matrix algebra. It uses random numbers from your own study. Often, but not always, better p-values are produced.

11 Note

More background, theoretical, and mathematical information of Monte Carlo methods for data analysis is given in Statistics applied to clinical studies 5th edition, Chap. 57, Springer Heidelberg Germany, 2012, from the same authors.
SPSS for Starters and 2nd Levelers
ACoverHTML.html
A211753_2_En_BookFrontmatter_OnlinePDF.html
A211753_2_En_1_ChapterPart1.html
A211753_2_En_1_Chapter.html
A211753_2_En_2_Chapter.html
A211753_2_En_3_Chapter.html
A211753_2_En_4_Chapter.html
A211753_2_En_5_Chapter.html
A211753_2_En_6_Chapter.html
A211753_2_En_7_Chapter.html
A211753_2_En_8_Chapter.html
A211753_2_En_9_Chapter.html
A211753_2_En_10_Chapter.html
A211753_2_En_11_Chapter.html
A211753_2_En_12_Chapter.html
A211753_2_En_13_Chapter.html
A211753_2_En_14_Chapter.html
A211753_2_En_15_Chapter.html
A211753_2_En_16_Chapter.html
A211753_2_En_17_Chapter.html
A211753_2_En_18_Chapter.html
A211753_2_En_19_Chapter.html
A211753_2_En_20_Chapter.html
A211753_2_En_21_Chapter.html
A211753_2_En_22_Chapter.html
A211753_2_En_23_Chapter.html
A211753_2_En_24_Chapter.html
A211753_2_En_25_Chapter.html
A211753_2_En_26_Chapter.html
A211753_2_En_27_Chapter.html
A211753_2_En_28_Chapter.html
A211753_2_En_29_Chapter.html
A211753_2_En_30_Chapter.html
A211753_2_En_31_Chapter.html
A211753_2_En_32_Chapter.html
A211753_2_En_33_Chapter.html
A211753_2_En_34_ChapterPart2.html
A211753_2_En_34_Chapter.html
A211753_2_En_35_Chapter.html
A211753_2_En_36_Chapter.html
A211753_2_En_37_Chapter.html
A211753_2_En_38_Chapter.html
A211753_2_En_39_Chapter.html
A211753_2_En_40_Chapter.html
A211753_2_En_41_Chapter.html
A211753_2_En_42_Chapter.html
A211753_2_En_43_Chapter.html
A211753_2_En_44_Chapter.html
A211753_2_En_45_Chapter.html
A211753_2_En_46_Chapter.html
A211753_2_En_47_Chapter.html
A211753_2_En_48_Chapter.html
A211753_2_En_49_Chapter.html
A211753_2_En_50_Chapter.html
A211753_2_En_51_Chapter.html
A211753_2_En_52_Chapter.html
A211753_2_En_53_Chapter.html
A211753_2_En_54_Chapter.html
A211753_2_En_55_ChapterPart3.html
A211753_2_En_55_Chapter.html
A211753_2_En_56_Chapter.html
A211753_2_En_57_Chapter.html
A211753_2_En_58_Chapter.html
A211753_2_En_59_Chapter.html
A211753_2_En_60_Chapter.html
A211753_2_En_BookBackmatter_OnlinePDF.html