Bootstrap and Jacknife Examples

For this example we create a small data set that has a Poisson distribution

Make/O/N=50 data1=30+poissonNoise(5)

To run bootstrap, in each iteration we draw (with replacement) 100 numbers and compute standard WaveStats on the drawn sample.

StatsResample/N=100 /ws=2/ITER=5 data1

The results for five iterations are shown in the table:

numPoints100100100100100
avg35.0935.2334.9535.2835.61
sdev2.193172.196672.203651.853632.14568
rms35.157835.297735.018735.328235.6739
adev1.831.81161.8321.51441.6914
skew-0.306796-0.1715490.107583-0.276227-0.483667
kurt-0.637302-0.595613-0.468839-0.173923-0.162058
sum35093523349535283561
meanL134.654834.794134.512734.912235.1843
meanL235.525235.665935.387335.647836.0357

Increasing the number of samples does not change the results substantially:

StatsResample/N=10000 /ws=2/ITER=5 data1

The results for five iterations are shown in the table:

numPoints1000010000100001000010000
avg35.216935.208935.231235.179935.2257
sdev2.042172.051212.069342.058972.04572
rms35.276135.268635.291935.240135.285
adev1.703271.718841.728271.719931.71226
skew-0.212116-0.199756-0.192836-0.177744-0.215313
kurt-0.424137-0.473013-0.439945-0.458874-0.450679
sum352169352089352312351799352257
meanL135.176935.168735.190635.139535.1856
meanL235.256935.249135.271835.220335.2658

Jacknife Example

We can use the Jacknife test to analyze the standard deviation of the same data. For this application our user function can be written in the form:

Function jackFunc(inWave)
Wave inWave
WaveStats/Q inWave
return V_sdev
End

To run the Jacknife test execute:

StatsResample/jckn=jackFunc data1

The results are displayed in the table:

N50
stdEstimate1.72
JKEstimate1.71928
JKTEstimate1.7551
sigmaJKEstimate0.165026

It is interesting to observe the differences between the standard deviation obtained by the bootstrap approach (above) to the oen obtained here.