[FIX] stats: Fix statistics for primitive variables#3722
Merged
ajdapretnar merged 1 commit intobiolab:masterfrom Apr 5, 2019
Merged
[FIX] stats: Fix statistics for primitive variables#3722ajdapretnar merged 1 commit intobiolab:masterfrom
ajdapretnar merged 1 commit intobiolab:masterfrom
Conversation
Codecov Report
@@ Coverage Diff @@
## master #3722 +/- ##
==========================================
- Coverage 84.52% 84.52% -0.01%
==========================================
Files 373 373
Lines 68459 68460 +1
==========================================
Hits 57868 57868
- Misses 10591 10592 +1 |
ajdapretnar
reviewed
Apr 5, 2019
| else: | ||
| nans = (~X.astype(bool)).sum(axis=0) if X.size else np.zeros(X.shape[1]) | ||
| X_str = X.astype(str) | ||
| nans = ((X_str == "nan") | (X_str == "")).sum(axis=0) \ |
Contributor
There was a problem hiding this comment.
I have my doubts about a literal 'nan' being treated as missing.
Contributor
|
@janezd @lanzagar @markotoplak How do you feel about a literal 'nan' being treated as missing? 'nan' can have meaning in English other than missing values (e.g. grandmother, naan bread). |
Contributor
|
Ok, we have decided to accept the current solution. We consider 'nan' to be a borderline case and if it ever arises, we will fix it then. |
3 tasks
3 tasks
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.
Issue
Fixes #3671
Description of changes
Includes