SPB Git

spb/wp29_uqo

Public

# F2-conf-02 — Is the memo's slope really significant?

# Question

The memo says the OLS slope of y on x (monthly, 1990-01 to 2023-04) is significant at the 5% level. It reached that conclusion with conventional i.i.d. standard errors. The task says the regression errors are serially correlated (AR(1), roughly 0.7), so I re-estimate the slope β in y_t = α + β x_t + u_t. I then test H0: β = 0 using a HAC (Newey–West, Bartlett kernel) standard error.

# Data and exclusions

data/series.csv has 400 rows (n_input_rows) covering 400 consecutive months. There are no missing values, no duplicate months and no gaps. No rows were excluded (out/exclusions.csv), so n_analysed = 400. data_issues is empty. Checksums and the full audit are in out/state/data_audit.md. I used the memo only for comparison: its numbers are recomputed, not taken as given.

# Method

  • OLS of y on a constant and x over the full sample. This gives alpha_hat and beta_hat. The conventional standard error se_iid is the baseline.
  • rho_resid is the first-order autocorrelation of the OLS residuals.
  • HAC standard error: Newey–West with a Bartlett kernel and the small-sample correction (statsmodels cov_type="HAC"). Bandwidth choice: Andrews (1991) AR(1) plug-in rule for the Bartlett kernel, applied to the slope score v_t = (x_t − x̄)·û_t. The score's AR(1) coefficient is rho_score. The raw bandwidth is andrews_bandwidth_raw = 8.18, rounded up to hac_lags = 9 months. I preferred this data-dependent rule because both the errors and x are persistent. The fixed Newey–West rule of thumb, floor(4(T/100)^{2/9}) = 5 (nw_rule_of_thumb_lags), adapts less to persistence. The script also reports a sensitivity grid of lag choices (hac_sensitivity).
  • Inference uses t_hac = beta_hat/se_hac with a standard normal reference distribution, a two-sided p_hac, and a 95% CI of beta_hat ± 1.96·se_hac.
  • The script uses no randomness (random_seed = null).

# Results

  • The memo's numbers reproduce: alpha_hat = 2.0925, beta_hat = 0.1017, se_iid = 0.0448, t_iid = 2.27, p_iid = 0.0238.
  • Residuals are strongly autocorrelated: rho_resid = 0.609.
  • With the HAC standard error: se_hac = 0.0654 with hac_lags = 9, which is about 1.46 times se_iid. This gives t_hac = 1.556 and p_hac = 0.120. The 95% CI is [beta_ci_low, beta_ci_high] = [−0.026, 0.230], which includes zero.
  • Verdict: the memo's claim that the slope is significant at 5% is not supported (memo_claim_supported = false). The point estimate is unchanged. Only the uncertainty was understated.

# Uncertainty

The conclusion does not depend on the bandwidth (hac_sensitivity). For every lag choice from 5 to 36 months, p is between 0.097 and 0.123. The only setting that gives p < 0.05 is lag 0 (p = 0.038), which is a heteroskedasticity-only correction with no allowance for autocorrelation. At 5% the slope is not significant; at 10% it is borderline at best.

# Limitations and open issues

  • HAC tests with a normal reference distribution are known to over-reject in small samples when the series are highly persistent. That would only weaken significance further, so it reinforces the verdict. I did not compute fixed-b or other refinements because the task does not require them.
  • The 95% CI is a large-sample approximation.
  • Not rejecting H0 does not show that β = 0. The data are simply not precise enough to establish significance at the 5% level.
  • The data are synthetic, as stated in TASK.md.
Files · 46a1f53512bec3cd5d9c16e8fc9d9da4129c09cc
Menu

Theme