Anchor Regression
Anchor regression is a linear regression that trades ordinary least squares against instrumental-variable estimation so that predictions stay accurate when the distribution shifts along directions driven by exogenous anchor variables such as site, batch or time.
앵커 회귀는 지역·배치·시기 같은 외생적 앵커 변수를 따라 분포가 바뀌어도 예측이 정확하도록 최소제곱과 도구변수 추정 사이에서 균형을 잡는 선형 회귀입니다.
My data come from several sites or periods; how do I fit a regression that will still predict well in a new site with shifted conditions?
자료가 여러 지역이나 시기에서 왔습니다. 조건이 달라진 새 지역에서도 잘 예측하는 회귀를 어떻게 적합합니까?
The outcome and predictors are split into the part explained by the anchors and the rest, and the anchor-explained part of the residuals is penalised by a factor gamma. Gamma = 1 is ordinary least squares, larger values protect against stronger shifts and move the estimate toward instrumental variables, and the reported path shows how coefficients change with gamma.
When to use Anchor Regression
- Data come from heterogeneous environments described by exogenous variables (site, batch, season, region).
- You care about prediction under future shifts of those environments, not only in-sample fit.
- You want a middle ground between OLS and IV.
When to use something else
- You want a causal effect with a valid instrument: use Two Stage Least Squares (2SLS)
- There are no environment variables that could act as anchors.
- The anchors are themselves affected by the outcome or predictors.
Assumptions and requirements
- Anchors are exogenous: not caused by the predictors, the outcome or hidden confounders
- Linear structural relations
- Future shifts act through the anchors and are no stronger than gamma
What the analysis reports
- Coefficients and intercept for the chosen gamma with bootstrap SEs
- Anchor objective, orthogonal and anchor-explained losses
- Coefficient path over gamma including OLS
- Indication of whether the IV limit is identified
How to report it
Anchor regression with gamma = [value] using [anchors] gave a coefficient of [value] for [predictor] (bootstrap SE = [value]) compared with [value] by OLS.
Related methods
- Two Stage Least Squares (2SLS)
- Instrumental Variable Estimation (IV)
- Weak Instrument Diagnostics and LIML
How this method is validated
이 방법의 검증 근거
- Independent computation. 1 reference test compares the results with direct computations (formulas, enumeration or simulation) at a stated tolerance of 1e-3.
독립 계산. 직접 계산(식·열거·모의실험) 대조 참조 시험 1건 통과(허용오차 1e-3).
Tolerances are relative differences (absolute differences for values near zero). R comparisons and reference tests are re-run before each release of the analysis engine.
허용오차는 상대 차이입니다(0 근처 값은 절대 차이). R 대조와 참조 시험은 분석 엔진을 배포할 때마다 다시 돌립니다.
Run Anchor Regression on Quorant
- Data you need
- a table (CSV or Excel) with an outcome variable, predictor (feature) columns and instrument
- Price
- 400 credits for one analysis up to 10,000 rows (complexity level 3); larger or wider data costs more. Optional methodologist review: 1800 credits.
- Checking
- Compared with independent computations
- Before you pay
- A free pre-analysis diagnosis checks your data and gives an exact quote; nothing is deducted until you approve it.