You can’t see this text!

Introduction to Computational Finance andFinancial Econometrics
The Bootstrap
Eric Zivot
Summer 2015

Eric Zivot (Copyright © 2015)

Bootstrap

1 / 11

Outline
1 Bootstrapping

Eric Zivot (Copyright © 2015)

Bootstrap

2 / 11

Bootstrapping

Motivation:
Before modern computers, doing statistical analysis involved using
mathematics and probability theory to derive statistical formulas
for standard errors and confidence intervals. Often these formulas
are approximations that rely on large samples
With modern computers and statistical software, resampling
methods (e.g. bootstrapping) can be used to produce standard
errors and confidence intervals without the use of formulas thatare often more reliable than statistical formulas

Eric Zivot (Copyright © 2015)

Bootstrap

3 / 11

Advantages of Boostrapping

Fewer assumptions
Do not need data to be normally distributed

Greater accuracy
Do not rely on very large sample sizes in contrast to Central Limit
Theorem

Generality
Same method applies to a wide variety of statistics

Eric Zivot (Copyright © 2015)

Bootstrap

4 / 11

Bootstrapping in the CER Modelrt = µ + t t = 1, · · · , Tt ∼ iid N (0, σ 2 )Observed sample:{r1 , . . . , rT }cc
Goal: Compute SE(µ̂)
and SE(σ̂)
and 95% confidence intervals for µand σ using the bootstrap. The analytic formulas are:σ̂σ̂ccSE(µ̂)= √ , SE(σ̂)≈√T2Tc θ̂), θ̂ = µ̂, σ̂θ̂ ± 2 · SE(Eric Zivot (Copyright © 2015)

Bootstrap

5 / 11

Procedure for Nonparametric Bootstrapping
1Resample - create B bootstrap samples by sampling withreplacement from the original data. Each bootstrap sample has T
observations (same as original sample):∗∗{r11, . . . , r1T} = 1st bootstrap sample

..
.
∗
∗
{rB1, . . . , rBT} = Bth bootstrap sample
2

Calculate bootstrap distribution for statistic of interest θ̂ - foreach bootstrap sample compute θ̂∗ . There will be B values of θ̂∗ :∗{θ̂1∗ , . . . , θ̂B}

3

Use the bootstrap distribution - the bootstrap distribution gives
information about the shape, center and spread of the unknown
pdf f (θ̂)

Eric Zivot (Copyright © 2015)

Bootstrap

6 / 11Bootstrap Estimates
Bootstrap estimate of bias:
B1 X
biasboot (θ̂, θ) =θ̂∗ − θ̂
B j=1 jbootstrap mean - estimatec θ̂):
Bootstrap estimate of SE(vuuc boot (θ̂) = utSE

2BB
1 X
1 Xθ̂ ∗ −θ̂∗ 
B − 1 j=1 j
B j=1 j∗sample SD of bootstrap values {θ̂1∗ , . . . , θ̂B}

Eric Zivot (Copyright © 2015)

Bootstrap

7 / 11Bootstrap 95% Confidence Intervals

1If bootstrap distribution is symmetric and looks normal use:c boot (θ̂)θ̂ ± 2 · SE

2If bootstrap distribution is not symmetric and looks non-normaluse:∗∗, q.975][q.025∗q.025= 2.5% quantile from bootstrap distribution∗q.975= 97.5% quantile from bootstrap distribution

Eric Zivot (Copyright © 2015)

Bootstrap

8 / 11

Performing the Bootstrap in R

Brute force
R package bootBrute force: perform the steps of the bootstrap by hand
123

sample with replacement from original data using sample()function B times
compute statistic from B bootstrap samples using for loop orapply() function
compute bootstrap bias and SE from bootstrap samples using
mean() and sd() functions

Eric Zivot (Copyright © 2015)

Bootstrap

9 / 11

Bootstrapping Value-at-Risk
In the CER model, 5% Value-at-Risk on an investment of $W isestimated using:d .05 = (e q̂.05 − 1)WVaR

q̂.05 = µ̂ + σ̂ · (−1.645)−1.645 = 5% quantile from N (0, 1)
Bootstrapping can be used to compute:c VaR
d .05 )SE(as well as confidence intervals.

Eric Zivot (Copyright © 2015)

Bootstrap

10 / 11

You can’t see this text!

faculty.washington.edu/ezivot/

Eric Zivot (Copyright © 2015)

Bootstrap

11 / 11