Robert_V._Hogg,_Joseph_W._McKean,_Allen_T._Craig

(Jacob Rumans) #1
310 Some Elementary Statistical Inferences

There are three outliers in the data sets.
Our test statistic for these data isv=y−x= 117. 74 − 111 .11 = 6.63. Computing
with the R functionboottesttwo, we performed the bootstrap algorithm given
above forB= 3000 bootstrap replications. The bootstrapp-value waŝp∗=0.169.
This means that (0.169)(3000) = 507 of the bootstrap test statistics exceeded the
value of the test statistic. Furthermore, these bootstrap values were generated under
H 0. In practice,H 0 would generally not be rejected for ap-value this high. In Figure
4.9.2, we display a histogram of the 3000 values of the bootstrap test statistic that
were obtained. The relative area to the right of the value of the test statistic, 6.63,
is approximately equal tôp∗.


  • 30 – 20 – 10 0 10 20


0

200

400

600

800

v*

Frequency

Figure 4.9.2:Histogram of the 3000 bootstrapv∗s. Locate the value of the test
statisticv=y−x=6.63 on the horizontal axis. The area (proportional to overall
area) to the right is thep-value of the bootstrap test.


For comparison purposes, we used the two-sample “pooled”t-test discussed in
Example 4.6.2 to test these hypotheses. As the reader can obtain in Exercise 4.9.8,
for these data,t=0.93 with ap-value of 0.18, which is quite close to the bootstrap
p-value.

The above test uses the difference in sample means as the test statistic. Certainly
other test statistics could be used. Exercise 4.9.7 asks the reader to obtain the
bootstrap test based on the difference in sample medians. Often, as with confidence
intervals, standardizing the test statistic by a scale estimator improves the bootstrap
test.
The bootstrap test described above for the two-sample problem is analogous to
permutation tests. In the permutation test, the test statistic is calculated for all
possible samples ofxsandys drawn without replacement from the combined data.
Often, it is approximated by Monte Carlo methods, in which case it is quite similar
to the bootstrap test except, in the case of the bootstrap, the sampling is done with

Free download pdf