Fix dof + improve collinearity detection#279
Open
matthieugomez wants to merge 1 commit into
Open
Conversation
f79c15d to
c4f209b
Compare
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #279 +/- ##
=======================================
Coverage ? 98.11%
=======================================
Files ? 8
Lines ? 691
Branches ? 0
=======================================
Hits ? 678
Misses ? 13
Partials ? 0 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
c4f209b to
4fb651f
Compare
Main fix: residual dof no longer subtracts the intercept twice — it is now N-K (and G-1 for clustered standard errors), matching Stata. The standard errors themselves were already correct. Also: - Collinearity detection is scale-invariant, so small-scale independent regressors are no longer wrongly dropped. - dof_fes ignores continuous-FE groups (fe(id)&x) whose interaction is all zero. - coeftable labels the confidence-interval columns with the requested level. - partial_out: deprecate method=:gpu and default tol to 1e-6 (so its residuals match reg). - Clearer errors (malformed formulas), new docstrings (fe, has_iv, has_fe, dof_fes, FixedEffectModel, collinear-omitted NaN convention), and small README fixes. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
4fb651f to
7bde4e4
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fix degrees-of-freedom reporting and improve API/docs
Main fix: residual dof no longer subtracts the intercept twice — it is now
N-K (and G-1 for clustered standard errors), matching Stata. The standard
errors themselves were already correct.
Also:
regressors are no longer wrongly dropped.
match reg).
dof_fes, FixedEffectModel, collinear-omitted NaN convention), and small
README fixes.
🤖 Generated with Claude Code