Repository navigation
MAINT: Avoid/Fix FutureWarnings - #5204
Conversation
|
@josef-pkt defacto green |
|
@josef-pkt green, fixes/avoids FutureWarnings |
|
|
||
| The parameter estimates solves the moment equation: | ||
|
|
||
| .. math:: (X' \\Sigma X + \\lambda R' \\sigma^2 \\Simga_p^{-1} R) b = X' \\Sigma y + \\lambda R' \\Simga_p^{-1} q |
There was a problem hiding this comment.
this is already properly escaped
There was a problem hiding this comment.
I thought adding the “r” to the docstring means you only use one backslash. Am I confusing this with something else?
There was a problem hiding this comment.
r means no escaping, without r backslash needs escaping ->\.
There was a problem hiding this comment.
I would use r and one \ since the docstring is mixed (some \ some \).
There was a problem hiding this comment.
@bashtage I thought that’s what I did here. Did I miss something?
There was a problem hiding this comment.
You are right, The docstring was mixed so you could have added r and moved to single escapes or left the r off and moved everything to double escape. I was mostly addressing @josef-pkt point about the escaping being correct which was right for that line but wrong for the docstring overall.
| @classmethod | ||
| def _drop_nans_2d(cls, x, nan_mask): | ||
| if hasattr(x, 'ix'): | ||
| if isinstance(x, (Series, DataFrame)): |
There was a problem hiding this comment.
maybe hasattr(x 'loc') to maintain the ducktyping
I don't know whether it matters here or not
There was a problem hiding this comment.
8 lines up this was changed last week, was missed here. It should definitely be consistent.
These are very specifically the two classes we want to catch.
|
@josef-pkt might be helpful to get this through before conflicts with 5220 arise |
|
@josef-pkt sounds like we have consensus here |
|
@josef-pkt any other requested changes? |
|
@josef-pkt can we get this in and clear some of the warnings out of the test logs? |
|
@josef-pkt there was briefly an interest in fixing these runtime warnings... lets finish the job |
|
including local cleanups does not mean pep-8ing the entire module. I think the |
|
Needs rebase. |
Codecov Report
@@ Coverage Diff @@
## master #5204 +/- ##
==========================================
- Coverage 81.98% 81.46% -0.52%
==========================================
Files 588 569 -19
Lines 93110 89718 -3392
Branches 10320 10043 -277
==========================================
- Hits 76332 73093 -3239
+ Misses 14406 14341 -65
+ Partials 2372 2284 -88
Continue to review full report at Codecov.
|
1 similar comment
Codecov Report
@@ Coverage Diff @@
## master #5204 +/- ##
==========================================
- Coverage 81.98% 81.46% -0.52%
==========================================
Files 588 569 -19
Lines 93110 89718 -3392
Branches 10320 10043 -277
==========================================
- Hits 76332 73093 -3239
+ Misses 14406 14341 -65
+ Partials 2372 2284 -88
Continue to review full report at Codecov.
|
|
Rebased, looks like all that is left is the wrapping of one 81-character line. |
Broken off from #5132.
The part remaining over there is internal use of apparently-deprecated statsmodels API. First pass at updating that usage broke a bunch of tests. This part should be pretty easy.