M3-008Hard结果解读 · Interpretation🔥 大厂高频出现 1 次

比率指标(如 CTR)的方差为什么不能直接用二项式公式?怎么算才对?

Why can't you use the binomial formula for the variance of a ratio metric like CTR? What should you do instead?
💡 考场高分一句话答案:

因为分子分母都是随机变量且相关,且分母会被处理效应改变;正确做法是按随机化单位聚合后用 delta method 或 bootstrap。

Because numerator and denominator are both random and correlated, and the denominator can be moved by the treatment. Aggregate to the randomisation unit and use the delta method or bootstrap.

📌 核心考察要点 (Key Points)

  • 问题一:$\mathrm{Var}(C/I)$ 不是 $p(1-p)/n$,需要 delta method 展开
  • 问题二:分析单位错配——把 impression 当独立样本会严重低估方差(同一用户的曝光高度相关)
  • 正确做法:按用户聚合成 $(C_u,I_u)$,对 $R=\sum C_u/\sum I_u$ 做 bootstrap 或线性化
  • 额外风险:分母内生(改动改变曝光量),需同时报告分子分母绝对变化
  • Problem one: $\mathrm{Var}(C/I)$ is not $p(1-p)/n$; it needs a delta-method expansion
  • Problem two: unit mismatch — treating impressions as independent badly understates variance, because one user's impressions are correlated
  • Correct approach: aggregate to $(C_u,I_u)$ per user, then bootstrap or linearise $R=\sum C_u/\sum I_u$
  • Additional risk: an endogenous denominator; report absolute numerator and denominator changes alongside

📐 第一性原理与数理推导机理

delta method:$$\mathrm{Var}\!\left(\frac{\bar C}{\bar I}\right)\approx\frac{1}{\mu_I^2}\left[\mathrm{Var}(C)-2\frac{\mu_C}{\mu_I}\mathrm{Cov}(C,I)+\frac{\mu_C^2}{\mu_I^2}\mathrm{Var}(I)\right]$$若 $C$ 与 $I$ 正相关(活跃用户曝光多且点击多),忽略协方差项会高估方差;若负相关则低估,导致假阳性。

⚖️ 业务权衡与取舍 (Trade-offs & Calibration)

Google 常用的替代方案是线性化(linearization / delta method on per-unit ratios):对每个用户计算 $Z_u=C_u-R\cdot I_u$,然后对 $Z_u$ 做两样本 t 检验。这在数学上等价于 delta method,但实现简单、可直接用标准检验,且天然支持 CUPED。

⚠️ 常见高频面试陷阱与避坑指南

  • 把 impression 当独立样本做 t 检验——p 值虚小,假阳性暴增
  • 只看比率不看分子分母绝对量

🔍 大厂面试官连环追问 (Follow-ups)

  • 什么时候可以用二项式近似?
  • 线性化方法与 delta method 的关系是什么?

🎯 关联大厂考题实战训练 (1 题)

嫌字多看太累?进入苏格拉底式对话推演实验室

零打字负担,以大厂考官真实困境切入,通过点选直觉选项暴露思维盲区,手把手推导 Why。

💬 开启对话式破冰 ➔
⚡
想检验本题的肌肉记忆?进入 3 阶闪卡主动回忆盲测
隐藏答案遮罩,自测:审题锚点 ➔ 数理公式机理 ➔ 工业标杆代码与连环追问。3 分钟攻破认知盲区!
🎯 立即在闪卡中盲测此题➔