Commit 5459463
Guard HC2/HC3 standard errors against fixed effects
HC2/HC3 compute leverage from the partialled-out (demeaned) regressors
only, omitting the absorbed fixed-effect contribution to leverage. This
silently understates leverage and yields anti-conservative standard
errors whenever fe() is used. Throw an informative ArgumentError for the
combination, mirroring the existing IV guard (HC2/HC3 are likewise
rejected for IV), and point users to Vcov.robust() (HC1) or Vcov.cluster().
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>1 parent 7bde4e4 commit 5459463
1 file changed
Lines changed: 7 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
118 | 118 | | |
119 | 119 | | |
120 | 120 | | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
121 | 128 | | |
122 | 129 | | |
123 | 130 | | |
| |||
0 commit comments