BOOTSTRAP_PR Politis-Romano method for correlated bootstrap
usage: [T] = bootstrap_pr(A, N, L);
arguments: A - range of integers 1:A to perform bootstrap on
N - length of integers to select bootstraps from
L - average length of bootstrap blocks. Each
bootstrap block has length k, such that:
1. P(k) = q*(1-q)^(k-1)
2. (P(k) * k> = L
3. q = 1/L
outputs: T - Nx1 vector of bootstrap indices
This function performs the 'stationary bootstrap' of integers
1:N according together the method detailed in:
Politis & Romano (1994) Journal Amer. Stat. Assoc.
This algorithm is used for drawing bootstrap samples from a
correlated time series indexed by the integers outputted from
this function.
Algorithm: We start with a random starting location, and with
probability q the next value is drawn again, and with probability
(1-p) it is consecutive from the previous value.
Original coding: Matt Kennel 2004
Edited: Shlens 2006-02-14
This function calls: