You are on page 1of 11

Essentials of Biostatistics in Public Health

Lisa M. Sullivan

This Excel workbook contains 10 worksheets to conduct tests of hypothesis for means (m), proportions (p), the mean difference
in matched or paired samples (md), the difference in means (m1-m2) and the difference in proportions (p1-p2) using the formula
and procedures outlined in Chapter 7 of Essentials of Biostatistics in Public Health.

For each analysis, either raw data (i.e. data measured on each participant in the study sample(s)) or summary data (e.g., samp
size, sample mean and sample standard deviation) can be entered into the worksheet to conduct the test of hypothesis. The
worksheets to compute the different tests of hypothesis are described below.

Worksheets to Conduct Tests of Hypothesis

1 - Test for m
Test of hypothesis for the mean of a population, continuous outome - Enter raw data into worksheet

2 - Test for m-Summary Data


Test of hypothesis for the mean of a population, continuous outome - Enter sample size, sample mean, sample standard
deviation

3 - Test for p
Test of hypothesis for the population proportion, dichotomous outome - Enter raw data into worksheet

4 - Test for p-Summary Data


Test of hypothesis for the population proportion, dichotomous outome - Enter sample size, number of successes in the sample
or the sample proportion

5 - Test for md
Test of hypothesis for the mean difference in matched or paired samples, continuous outome - Enter raw data into worksheet

6 - Test for md-Summary Data


Test of hypothesis for the mean difference in matched or paired samples, continuous outome - Enter sample size, sample mean
difference, sample standard deviation of differences

7 - Test for (m1-m2)


Test of hypothesis for the difference in two independent means, continuous outome - Enter raw data into worksheet

8 - Test for (m1-m2)-Summary Data


Test of hypothesis for the difference in two independent means, continuous outome - Enter sample sizes, sample means, samp
standard deviations

9 - Test for (p1-p2) (NOTE: Also computes CI for relative risk and odds ratio)
Test of hypothesis for the difference in two independent proportions, dichotomous outome - Enter raw data into worksheet

10 - Test for (p1-p2)-Summary Data


Test of hypothesis for the difference in two independent proportions, dichotomous outome - Enter sample sizes, numbers of
successes or sample proportions in each group
One Sample Test for m sbp Level of Significance 5%
120 Mean Under H0 130.00
INSTRUCTIONS 130
150
170 RESULTS
n 4
Enter Your Data in Column C (Yellow).
Mean 142.500
Place the Variable Name in Cell C2 Std Dev 22.174
and the Data Starting in Cell C3.
SE 11.087
Then Enter the Details of the Test of Hypothesis t 1.127
In the Designated Cells in Column F (Yellow). One sided p-value 0.1708
Results Will Show in Green Cells. Two sided p-value 0.3416

Note: You must "DELETE" old data in Column C before


starting a new analysis.
One Sample Test for m Level of Significance 5%
Mean Under H0 130.00
INSTRUCTIONS

SUMMARY STATISTICS
n 20
Enter the Details of the Test of Hypothesis Mean 125.00
In the Designated Cells in Column D (Yellow). Std Dev 14.00
Then Enter Sumary Statistics
(n, Sample Mean, Sample Standard Deviation) RESULTS
In Cells D7 Through D9 (Yellow). SE 3.130
Results Will Show in Green Cells. t -1.597
One sided p-value 0.0634
Two sided p-value 0.1267
One Sample Test for p X Level of Significance 5%
1 Proportion Under H0 0.50
INSTRUCTIONS 0
0 RESULTS*
1 n 20
1 Sample Proportion 0.350
Enter Your Data in Column C (Yellow). 1 Std Dev 0.477
Code Data as 0=No and 1=Yes.
1 SE 0.107
Place the Variable Name in Cell C2 0 Z -1.342
and the Data Starting in Cell C3.
0 One sided p-value 0.090
Then Enter the Details of the Test of Hypothesis 1 Two-sided p-value 0.180
In the Designated Cells in Column F (Yellow). 0
Results Will Show in Green Cells. 1
0 *Min(np,n(1-p))>=5
0
Note: You must "DELETE" old data in Column C before 0 13
starting a new analysis. 0 7
0
0
0
0
One Sample Test for p Level of Significance 5%
Proportion Under H0 0.50
INSTRUCTIONS
SUMMARY STATISTICS
n 20
Number of Successes 6
or Sample Proportion
Enter the Details of the Test of Hypothesis
In the Designated Cells in Column D (Yellow). RESULTS*
Then Enter Summary Statistics Sample Proportion 0.300
(n, Number of Successes or Sample Proportion) Std Dev 0.458
in Cells D6 and Either D7 or D8 (Yellow). SE 0.102
Results Will Show in Green Cells. Z -1.789
One sided p-value 0.037
Two-sided p-value 0.074

*Min(np,n(1-p))>=5
Two Dependent Samples CI for m d Basline 6 Months Differences Level of Significance 5%
215 205 10 Mean Difference Under H0 0.00
INSTRUCTIONS 190 156 34
230 190 40 RESULTS
220 180 40 n (Number of Pairs) 15
214 201 13 Mean Difference 16.933
Enter Your Data in Columns C & D (Yellow).
240 227 13 Std Dev of Difference 14.165
Place the Variable Names in Cells C2 & D2 210 197 13 SE 3.657
and the Data Starting in Cells C3 & D3.
193 173 20 t 4.630
Then Enter the Details of the Test of Hypothesis 210 204 6 One sided p-value 0.000
in the Designated Cells in Column H (Yellow). 230 217 13 Two sided p-value 0.000
Results Will Show in Green Cells. 180 142 38
260 262 -2
210 207 3
Note: You must "DELETE" old data in Columns C & D 190 184 6
before starting a new analysis. 200 193 7
Two Dependent Samples CI for m d Level of Significance 5%
Mean Difference Under H0 0.00
INSTRUCTIONS
SUMMARY STATISTICS
n (Number of Pairs) 20
Mean Difference 0.08
Enter the Details of the Test of Hypothesis Std Dev of Difference 0.30
in the Designated Cells in Column D (Yellow).

Then Enter Summary Statistics RESULTS


(n, Sample Mean Difference, Standard
Deviation of the Difference Scores) SE 0.067
in Cells D5 Through D7 (Yellow). t 1.193
One sided p-value 0.124
Results Will Show in Green Cells. Two sided p-value 0.248
Two Independent Samples Test for (m 1 -m 2) Drug Placebo Level of Significance 5%
125 145 Difference in Means Under H0 0.00 $C$3
INSTRUCTIONS 130 140 $C$11
135 132 RESULTS
121 129 Group 1 Group 2
Enter Your Data in Columns C & D (Yellow).
140 145 n 9 9
Place the Variable Names in Cells C2 & D2 137 150 Mean 130.778 140.111
and the Data Starting in Cells C3 & D3.
129 160 Std Dev 9.523 11.911 n1>=30
Then Enter the Details of the Test of Hypothesis 145 140 SE 3.174 3.970 n2>=30
In the Designated Cells in Column G (Yellow). 115 120 Sp 10.783
Results Will Show in Green Cells. t -1.836
One sided p-value 0.042
Two sided p-value 0.085
Note: You must "DELETE" old data in Columns C & D
before starting a new analysis.
Two Independent Samples Test for (m 1 -m 2 ) Level of Significance 5%
Difference in Means Under H0 0.00 $C$3
INSTRUCTIONS $C$11
SUMMARY STATISTICS
Group 1 Group 2
Enter Your Data in Columns C & D (Yellow).
n 9 9
Place the Variable Names in Cells D6 & E6 Mean 130.80 140.10
and the Summary Statistics Starting in Cells D7 & E7.
Std Dev 9.50 11.90 n1>=30
Then Enter the Details of the Test of Hypothesis n2>=30
In the Designated Cells in Column D (Yellow). RESULTS
Results Will Show in Green Cells. SE 3.167 3.967
Sp 10.767
t -1.832
One sided p-value 0.043
Two sided p-value 0.086
Two Independent Samples Test for (p1-p2 ) Var1 Var2 Level of Significance 5%
0 0 Difference in Proportions Under H 0 0.00
INSTRUCTIONS 0 0 $C$3
0 0 RESULTS* $C$52
0 0 Group 1 Group 2
0 0 n 50 50
Enter Your Data in Columns C & D (Yellow).
0 0 Sample Proportions 0.460 0.240
Place the Variable Names in Cells C2 & D2 0 0 Difference in Proportions 0.220
and the Data Starting in Cells C3 & D3.
0 0 SE 0.093
Then Enter the Details of the Test of Hypothesis 0 1 Z 2.370
In the Designated Cells in Column G (Yellow). 0 0 One sided p-value 0.009
Results Will Show in Green Cells. 0 0 Two sided p-value 0.018
0 0
0 0 Relative Risk (RR) 1.917
Note: You must "DELETE" old data in Columns C & D 0 0 Odds Ratio (OR) 2.698 ln(RR)
before starting a new analysis. 0 0
0 0 *Min(n1p1,n1(1-p1),n2p2,n2(1-p2))>=5
0 0
0 0
0 0 ln(OR)
0 0 SE
0 0
0 0
0 0
0 0 27
0 0 23
0 0
0 0
1 0
1 0
1 0
1 0
1 0
1 0
1 0
1 0
1 0
Two Independent Samples Test for (p1-p2) Level of Significance 5%
Difference in Proportions Under H0 0.00
INSTRUCTIONS $C$3
SUMMARY STATISTICS
Group 1 Group 2
n 80 80
Enter the Details of the Test of Hypothesis Number of Successes
In the Designated Cells in Column D (Yellow).
or Sample Proportion 0.20 0.50
Then Enter Summary Statistics
(n, Number of Successes or Sample Proportions
In Each Group) in Cells D6 and E6 and Either RESULTS*
D7 and E7 (Numbers of Successes) or Group 1 Group 2
D8 and E8 (Sample Proportions). Sample Proportions 0.200 0.500
Results Will Show in Green Cells. Difference in Proportions -0.300
SE 0.072
Z -4.191 ln(RR)
One sided p-value 0.000
Two sided p-value 0.000

Relative Risk (RR) 0.400


Odds Ratio (OR) 0.250 ln(OR)
SE
*Min(n1p1,n1(1-p1),n2p2,n2(1-p2))>=5

You might also like