A block, weighted inside itself

A block weighted inside itself

The triangle every block resample attenuates by is not a fact about blocks. It is the self-convolution of a rectangle, and a block weighted down towards its own ends has a different one — whose leading term is the squared value at the two ends and nothing else about the shape.

Worth reading first: Where the bootstrap lies · The observations that repeat each other.

Three constructions in this collection attenuate a resampled series’ dependence, and all three tapers were inherited rather than chosen. A multiplier shared along a block keeps (1 − k/ℓ)⁺ of the covariance at lag k, because a pair straddling a sign change contributes nothing. A fixed-length moving block keeps exactly the same triangle, for the same reason — the attenuation is the join. And the stationary bootstrap, whose runs are geometric rather than exactly ℓ long, keeps (1 − 1/ℓ)^k.

None of those three has a window in it. The construction most of the long-run-variance literature actually runs does: the residuals inside each block are weighted down towards the block’s own ends before the blocks are laid end to end.

The triangle is a self-convolution

Write the weights as a window w on the unit interval, so that the residual at position u of a block is used at weight w(u). A lag-k pair inside a block carries w(u)w(u + k/ℓ), and averaging over where in the block the pair sits gives

κ(x)  =  w(u)w(u+x)duw(u)2du,x=k.\kappa(x) \;=\; \frac{\int w(u)\,w(u + x)\,du}{\int w(u)^2\,du}, \qquad x = \frac{k}{\ell}.

At w ≡ 1 that integral is 1 − x. The triangle is the self-convolution of a rectangle, and it is not a statement about blocks at all: it is a statement about the window a block happens to use when nobody chooses one.

Four blocks, and only the ends matter. The weights a block carries, normalised so that the resample keeps the residuals' variance and only their covariances are attenuated. What separates these shapes, for everything that follows, is the value at the two ends and nothing about the middle: the first-order attenuation is −(w(0)² + w(1)²)/(2∫w²), which is -1.0000 for the rectangle, -0.3896 for the trapezoid cut off at half height, and exactly zero for both windows that reach the axis. The half-height trapezoid is in the table to be the case that separates a shape from a boundary value: it is smooth, it is tapered, and it buys none of the order the other two buy.
Fig. 1 Four windows, normalised so that the resample keeps the residuals’ variance and only their covariances are attenuated.
What each block keeps, lag by lagThe attenuation each construction applies at each lag, in a block of 20. A rectangular block gives exactly the triangle 1 − k/ℓ, which is not a fact about blocks: it is the self-convolution of a rectangle, and every other window has one of its own. The trapezoid keeps 0.987 at the first lag against the rectangle's 0.950 and 0.263 at the half-block against 0.500, so it holds the short lags almost intact and gives up the long ones faster. The dashed line is the stationary bootstrap's geometric taper, which comes from randomising the block length rather than from weighting inside it, and is the only one of the five that is never exactly zero.00.2500.5000.7501010203040lag, in a block of 20the share of the covariance the resample keepsa rectangular blocka trapezoid cut off at half heightthe usual trapezoida raised cosinegeometricclosed form, from each window's self-convolutionthe triangle is the rectangle's
Fig. 2 And what each one keeps, lag by lag, with the block length on the slider.

The shapes differ where the taper is doing its work. At ℓ = 20 the trapezoid keeps 0.987 of the first lag against the rectangle’s 0.950, and 0.263 of the tenth against the rectangle’s 0.500: it holds the short lags almost intact and gives up the middle of the block faster. That is the trade the construction is for, and it is visible in the picture rather than argued for.

The geometric taper dominates the triangle, provably

Two of the three inherited tapers can be compared without any measurement at all, and one of them wins everywhere.

The triangle keeps 1k/1 - k/\ell and the stationary bootstrap keeps (11/)k(1 - 1/\ell)^k. Since ex1xe^{-x} \ge 1 - x for every x, and (11/)k(1-1/\ell)^k is very close to ek/e^{-k/\ell},

(11)k    1k\left(1 - \tfrac{1}{\ell}\right)^{k} \;\ge\; 1 - \tfrac{k}{\ell}

at every lag and every block length, with a gap of about k2/(22)k^2/(2\ell^2) to leading order. At ℓ = 20 the two agree at the first lag — 0.950 each — and by the tenth the geometric keeps 0.599 against the triangle’s 0.500.

So the construction with random block lengths attenuates less than the one with fixed blocks, at every lag, and the reason is convexity rather than anything about resampling: a geometric run length has a chance of being long, and the long runs carry the far pairs that a fixed block of exactly ℓ always cuts.

And the totals differ by exactly two

Summed over all lags — which is what a long-run variance reads — the comparison is not merely a domination but a clean factor.

k=11(1k)=12,k1(11)k=1.\sum_{k=1}^{\ell-1}\left(1-\frac{k}{\ell}\right) = \frac{\ell-1}{2}, \qquad \sum_{k\ge1}\left(1-\frac{1}{\ell}\right)^{k} = \ell - 1 .

Exactly twice, at every block length, with no approximation. At ℓ = 20 that is 9.5 against 19.

That is worth holding beside the field’s own trade-off. The trapezoid buys short lags at the cost of the middle of the block — 0.987 against 0.950 at the first lag, 0.263 against 0.500 at the tenth — which is a reallocation of a roughly fixed budget. The stationary bootstrap does not reallocate; it has twice the budget, because its runs are unbounded rather than capped at ℓ.

Two spreads, from the same three numbers at ℓ = 20. At the first lag the three tapers keep 0.950, 0.950 and 0.987 — within four points of each other, so nothing a short-lag comparison could distinguish. At the tenth they keep 0.500, 0.599 and 0.263, a factor of 2.3 from end to end.

The choice of taper is invisible where the dependence is strongest and decisive where it is weakest, which is exactly backwards from how a block length is usually chosen, and it is why a construction whose window nobody picked can be wrong by a factor while every short-lag diagnostic agrees.

The ends of the window are the order of the bias

The useful statement is not about the shape. Differentiate the numerator at x = 0. The upper limit of the integral moves, which leaves one boundary term, and the remaining integral of w w′ is itself a boundary term by the fundamental theorem of calculus. What survives is

κ(0)  =  w(0)2+w(1)22w2.\kappa'(0) \;=\; -\,\frac{w(0)^2 + w(1)^2}{2\int w^2}.

The first-order attenuation is the squared values at the two ends of the block and nothing else about the window. A rectangle has κ′(0) = −1. Any window that reaches zero at both ends has κ′(0) = 0, so its attenuation is second order in k/ℓ, and the bias it leaves in a long-run variance is O(ℓ⁻²) where a rectangle’s is O(ℓ⁻¹).

That is the whole of what a taper buys, and it is worth being exact about what it does not buy: nothing about smoothness, nothing about the middle of the window, nothing about how gently the weights fall. Two windows with the same end values have the same leading term however differently they are shaped in between.

The window that is tapered and buys nothing

A claim of that form should be refutable, and the refutation is easy to build: take the trapezoid the construction is usually written with and cut it off at half height. It still rises and falls, it is still smooth, it still down-weights the block’s ends. It reaches 0.5 rather than 0, so it must stay first order, at κ′(0) = −0.3896 against the rectangle’s −1.

A first order and a second order are two slopes. The bias in the long-run variance each construction implies, computed exactly on an autoregression at 0.7 with no sampling anywhere in it, against the block length. The rectangle's falls like ℓ^-1.00 and the geometric taper's like ℓ^-0.99; the two windows that reach zero at the block's ends fall like ℓ^-1.95 and ℓ^-1.97. The trapezoid cut off at half height falls like ℓ^-1.13, which is the first order with a small coefficient rather than the second order with a large one — its κ'(0) is -0.390 against the rectangle's -1.000, and at these block lengths the two terms are still competing.
Fig. 3 The bias in the implied long-run variance against the block length, on log axes, computed in closed form with no sampling anywhere in it. A first order and a second order are two different slopes.

Measured as the slope of log|bias| against log ℓ over the longest four block lengths: the rectangle falls at −1.00, the stationary bootstrap’s geometric taper at −0.99, the trapezoid at −1.95 and the raised cosine at −1.97. The half-height trapezoid falls at −1.13 — the first order with a small coefficient, still shedding its second-order term at these lengths, and heading for −1 rather than −2.

Nothing here is estimated. The autocovariance is ρ^k at ρ = 0.7, the long-run variance is (1 + ρ)/(1 − ρ) = 5.6667 exactly, and each construction’s implied value is Σ κ(k)γ(k) summed to four hundred lags. The disagreement between a first order and a second order is a fact about two sums.

Three routes to the attenuation

The closed form knows nothing about a residual series. So it is checked against two things that do.

The first is the expectation written out from the construction’s own mechanism on a particular sample: a lag-k pair at position j of a block carries wjwj+kw_j w_{j+k} times the average product over the block’s starting positions, summed over the positions where a pair stays inside one block. The second is the average of realised resamples — draw the blocks, lay them out, measure the autocovariance of what comes out.

Three routes to what a tapered block keeps. The trapezoid at ℓ = 10, over 60 draws with 60 resamples each. The upper line is what the residuals themselves carry. The lower line is the closed prediction — the residuals' autocorrelation times the window's own self-convolution — and the dots are the average of realised resamples, which share no arithmetic with it: the resampler knows about weights and block starts, and the prediction knows about an integral. The open marks are a third route, the expectation written out from the construction's mechanism on each particular residual series. The worst departure between the prediction and the count is 2.1 standard errors.
Fig. 4 The trapezoid at ℓ = 10 by three routes. The prediction is the residuals’ own autocorrelation times the window’s self-convolution; the dots are realised resamples, which know about weights and block starts and nothing about an integral.

They agree to within the noise of the count. This is the site’s usual discipline and it earns its keep here for a specific reason: the self-convolution is derived under an approximation — that the average product over starting positions is the same at every position in the block — and the mechanism route does not make that approximation. Their agreement says the approximation is not carrying anything.

And at the block lengths anybody can use, the ranking is upside down

Everything above is asymptotic. The block lengths in it run to five hundred, and the samples this collection resamples have a hundred and twenty rows.

Where the taper starts paying, and it is not here. The same bias at the block lengths a sample of a hundred and twenty rows can actually support. The ordering is upside down: at ℓ = 8 the rectangle is at -32.3% and the trapezoid at -37.9%, so the window that is better by an order of magnitude asymptotically is worse by six points here. They cross at ℓ = 20. The stationary bootstrap's geometric taper, which has no asymptotic advantage at all, has the smallest bias of the five at every block length up to 32 — because its runs have no hard cut-off, so it keeps something at every lag rather than nothing past ℓ.
Fig. 5 The same bias at block lengths a hundred and twenty rows can support. The window that is better by an order of magnitude asymptotically is worse than the rectangle everywhere left of ℓ = 20.

At ℓ = 8 — a block length a sample of this size can actually afford — the rectangle’s implied long-run variance is 32.3% low, the trapezoid’s is 37.9% low and the raised cosine’s is 42.3% low. The tapered block is worse, by six and ten points, in exactly the regime where anybody would use it. The rectangle and the trapezoid cross at ℓ = 20, which is a sixth of the sample, and the raised cosine does not overtake the rectangle until about thirty.

The reason is not subtle. A taper throws information away: weighting the ends of a block down means the resample uses less of each block, and at ℓ = 8 there is not much block for the middle of the window to be flat over. What the taper buys is a term that vanishes faster, and a term that vanishes faster is not smaller until ℓ is large enough for both terms to be small.

The best of the five at every block length below thirty is the one with no asymptotic advantage at all: the stationary bootstrap’s geometric taper, at 26.6% low at ℓ = 8. Its runs have no hard cut-off, so it keeps something at every lag rather than nothing past ℓ, and at short blocks that matters more than the order of anything.

A new dial, or the old one relabelled

If a taper and a block length both attenuate, it is fair to ask whether the taper is a new tuning parameter at all or a way of writing a shorter block. The question has an answer: find the rectangle whose attenuation is nearest the taper’s, weighting each lag by how much covariance a series at ρ = 0.7 actually has there.

At ℓ = 8 the answer is a rectangle of 6 — three quarters of the length — and the largest gap between the two attenuations at any lag inside the block is 0.091. At ℓ = 12 it is a rectangle of 9, again three quarters, with the same 0.092. So at the block lengths a hundred and twenty rows permit, a tapered block of ℓ is very nearly a plain block of 0.75ℓ, and choosing the taper is choosing the block length by another name.

The two come apart as the blocks grow, which is exactly where the order does its work. At ℓ = 32 the nearest rectangle is 32 and the worst gap is 0.264; at ℓ = 64 the nearest rectangle is 104 and the gap is 0.512. The shapes are then genuinely different objects, and the difference is the second-order behaviour that the order of the bias is about.

This is worth stating because it is the strongest form of the finite-sample point. It is not that the taper’s advantage is small at short blocks — it is that at short blocks the taper is not doing anything a block length was not already doing, and the two dials are one dial until the sample is long enough for them to separate.

Why a resampling can never produce a negative variance

There is one thing every construction here gets for nothing, and it is worth naming because the obvious direct estimator does not get it.

A truncated sample autocovariance sequence — every lag inside a window at full weight, everything outside it at zero — is not always a covariance matrix. On residuals from a persistent design it fails to be one on most draws, which is why every window in that field is tapered rather than cut.

A resampling cannot have that problem. The lag window it implies is a self-convolution, and the Fourier transform of a self-convolution is |ŵ(ω)|², which is non-negative at every frequency. So the long-run variance a block resample implies is a non-negative-definite estimator by construction, whatever window is put inside the block and whatever the sample looks like — the positive-definiteness the Bartlett and Parzen windows have to be chosen for is automatic here, because a resample is built by squaring something rather than by writing a matrix down.

That is a real advantage of the construction and it is invisible in every number above, all of which are expectations. It is also the reason the same triangle appears in two places that look unrelated: the Bartlett window that makes a direct estimator positive semidefinite is the self-convolution of a rectangle, and so is the attenuation of a block resample. They are the same object arrived at from two directions.

What a taper does to the second moment as well

A bias is half of a comparison and the honest reading needs the other half, which this essay measures only indirectly.

Weighting a block’s ends down reduces the effective number of residuals each block contributes, so the resampled series is built from less independent information and its statistics are more variable from resample to resample. That variability does not appear anywhere in the closed forms above, because those are expectations. It appears in the width of a reference distribution, and what each construction’s reference distribution is worth is the measurement that carries it.

The direction is predictable and the size is not, which is why it is measured rather than argued. What can be said here is that the two effects point the same way at short blocks: a taper has a larger bias and a larger variance there, so nothing about the finite-sample case is being hidden by reporting only the bias.

What this says about choosing a block length

The measurements above are all about the bias in one quantity, and they arrive at a recommendation narrow enough to state exactly.

For a sample of a hundred and twenty rows, the block lengths that leave enough blocks to resample are somewhere between four and a dozen. In that range the ranking is: the stationary bootstrap’s geometric taper first, the rectangle second, the trapezoid third, the raised cosine last — and the gaps are not small, running from 26.6% to 42.3% of the long-run variance at ℓ = 8. Whatever the literature’s argument for tapering is, it is not an argument about this range.

The range where it becomes one starts at about twenty, which for these samples means a block that is a sixth of the series and only six blocks to lay end to end. That is a different failure — a resample built from six blocks has very little of its own randomness left — and it is the reason the crossing point is a curiosity rather than a recommendation.

The honest summary is that the taper’s asymptotic advantage is real, is exactly the boundary value of its window, and needs a sample several times longer than the ones this collection resamples before it is worth anything. That is not an argument against the construction; it is an argument for measuring where its crossing is before adopting it, which is one closed-form sum and needs no simulation at all.

What is claimed here, and what is not

This essay takes what a block’s own window does to what a resample keeps. The claims are that the attenuation is the window’s normalised self-convolution, so the triangle is a rectangle’s rather than a block’s; that the first-order term is −(w(0)² + w(1)²)/(2∫w²), the squared end values and nothing else; that a window reaching zero at both ends therefore has a second-order bias, measured at slopes of −1.95 and −1.97 against −1.00 and −0.99 for the windows with weight at their ends; that a trapezoid cut off at half height is tapered, smooth, and still first order; and that at every block length below twenty the untapered rectangle has the smaller bias, with the geometric taper smaller still.

What stays out and is named as a decision: which window is best. The trapezoid’s corner at 43% of the block is the standard choice and nothing here optimises over it, or over the family of windows a κ′(0) of zero admits. Choosing the window to minimise a measured bias would be choosing it on the same table it is being priced on, which is the trap the tuning parameters in this collection keep meeting, and there is no reason to think this one escapes it — the same trap as the term a chosen window drops.

The other omission is the block length itself. Every number above is a function of ℓ and none of them choose it, which is what a sample of a hundred and twenty rows can actually afford and a field of its own. The crossing at twenty is where the ranking changes, not where either construction is good — and bias is not the whole of what a block length is trading.

The checks, and the refusal

Three claims are gated. A rectangular block’s attenuation is required to be the triangle at every lag, to 10⁻¹², because every statement in this collection about what a block keeps is downstream of that. The first-order term computed from the continuous window is required to agree with the discrete κ at the first lag times the block length, which is the check that the identity is about the window rather than about one block length’s arithmetic. And the three routes to the attenuation are required to agree.

The refusal is the half-height trapezoid. A taper credited with an order it does not have is rejected: its bias falls like 1.13\ell^{-1.13} where the trapezoid that reaches zero falls like 1.95\ell^{-1.95}, and the difference between them is the boundary value rather than anything a reader would call the shape.

What links here

Computed from the collection, not written here: the essays that point at this one.

Shares its objects with

Essays that name at least two of the same things, and that neither author linked.

  • A length for each instrument — both name bias-variance, block bootstrap, dependence, long-run variance, reference distribution, resampling, stationary bootstrap, tapering
  • The residuals are not the errors — both name autocorrelation, block bootstrap, dependence, long-run variance, reference distribution, resampling, residual, wild bootstrap
  • Errors generated from a fitted model — both name autocorrelation, block bootstrap, dependence, reference distribution, resampling, residual, wild bootstrap
  • How long a block a multiplier shares — both name autocorrelation, bias-variance, block bootstrap, reference distribution, resampling, residual, wild bootstrap
  • The length nobody has — both name bias-variance, block bootstrap, closed form, dependence, long-run variance, resampling, tapering
  • An interval that carries its scale — both name block bootstrap, closed form, dependence, long-run variance, reference distribution, resampling

Named objects

A flat tag is an object no other essay names yet.

AutocorrelationBandwidth selectionBiasBias-varianceBlock bootstrapClosed formDependenceLong-run varianceReference distributionResamplingResidualStationary bootstrapTaperingVarianceWild bootstrap