M1-082M1: Mathematics & Statistics FundamentalsConfidence Intervals & BootstrapHard
Mastery:

Confidence Intervals & Bootstrap: 解释 block bootstrap 与它在时间序列中的作用。

📐 Mathematical Definition
block bootstrap: resample blocks of length L\text{block bootstrap}:\ \text{resample blocks of length } L
⚡ Executive Summary
Core Concept: 对连续块(而非单点)重采样,保留时间依赖结构;否则朴素 bootstrap 会破坏自相关。

📌 Key Takeaways

  • •
    块长 L 需大于自相关衰减尺度
  • •
    变体:moving block / stationary / circular block

📐 Mathematical Derivations

问题的根源:朴素 bootstrap 假设样本<strong>独立同分布</strong>,从中有放回抽单个点会<strong>破坏时间依赖结构</strong>(相邻点被随机打散),导致重采样样本的自相关结构消失,从而<strong>低估长期统计量的方差</strong>(如均值的方差在有正自相关时会远大于 i.i.d. 情形)。<strong>block bootstrap 的解法</strong>:不再抽单点,而是抽<strong>连续块</strong>(长度 L),把块拼接成新的序列——这样块内的依赖结构被完整保留。三种常见变体:① <strong>moving block bootstrap(MBB)</strong>——从所有可能的长度为 L 的连续块中均匀抽样(块数 n−L+1),拼接后取前 n 个点;② <strong>non-overlapping block bootstrap(NBB)</strong>——把序列切成不重叠的块后抽样(块数少,方差大);③ <strong>stationary bootstrap</strong>——块长<strong>随机</strong>(几何分布,均值 L),保证重采样序列是平稳的(MBB 拼接处会产生人为的不连续)。<strong>块长 L 的选择</strong>是关键超参:应大于自相关显著衰减的尺度(如取 n^{1/3} 或用自相关函数判断),L 太小则依赖结构仍被破坏、太大则有效块数少、方差大。

🏭 Production Trade-offs

应用与要点:① <strong>A/B 测试中的时间相关</strong>——若实验单位是时间(switchback 实验、时间序列指标),指标存在自相关,用朴素 bootstrap 会低估方差导致假阳性;应用 block bootstrap。② <strong>聚类/分组数据</strong>——同一用户的多条记录、同一商品的多期数据构成'组',此时用 <strong>cluster bootstrap</strong>(对整组重采样),与 block bootstrap 思想一致(都是'重采样依赖单元')。③ <strong>与 HAC 标准误的关系</strong>——时间序列回归中常用 <strong>Newey-West(HAC)</strong> 标准误处理自相关与异方差,它在理论上与 block bootstrap 目标相同(都是正确估计长期方差);HAC 有解析式但需选带宽,block bootstrap 更灵活。④ <strong>块长的实用选择</strong>——常用规则 L≈n^{1/3}(对均值类统计量)、或根据自相关函数的衰减到 0.1 以下的滞后阶数;应做<strong>敏感性分析</strong>(不同 L 下结果是否稳健)。⑤ <strong>局限</strong>——block bootstrap 假设序列<strong>平稳</strong>(分布不随时间变化);若存在趋势或结构突变,需先去趋势或用 wild bootstrap。⑥ <strong>计算成本</strong>——比朴素 bootstrap 稍贵(需管理块索引),但实现简单。
⚠️ Common Interview Pitfalls
  • ✕
    对时间序列用朴素 bootstrap(低估方差)
  • ✕
    块长 L 远小于自相关尺度(依赖结构仍被破坏)
🎯 Interviewer Follow-ups
  • ?
    为什么朴素 bootstrap 对时间序列失效?
  • ?
    块长 L 如何选择?
📚

Associated Knowledge Base Guides & Mindmaps

Explore the comprehensive technical article, exam cards, and global architecture tree.

← PreviousM1-081: Confidence Intervals & Bootstrap: 解释 delta method 与它的适用条件。📋Back to BankNext →M1-083: 实验设计 (A/B): 解释分层随机化与它何时必要。