Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[ENH] Table.from_numpy: Replace infs with nans. #3624

Merged
merged 2 commits into from
Feb 25, 2019
Merged

Conversation

thocevar
Copy link
Contributor

Issue

Implements #2788

Description of changes

Replace infs in a numpy array with nans and raise a warning.

Includes
  • Code changes
  • Tests
  • Documentation

a = np.array([[2, 0, 0, 0],
[0, np.nan, np.nan, 1],
[0, 0, np.inf, 0]])
with self.assertWarns(Warning):
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please remove spaces or disable the pylint warning. I now it's stupid, but it pollutes the output on travis.

@codecov
Copy link

codecov bot commented Feb 25, 2019

Codecov Report

Merging #3624 into master will increase coverage by <.01%.
The diff coverage is 100%.

@@            Coverage Diff             @@
##           master    #3624      +/-   ##
==========================================
+ Coverage   84.07%   84.07%   +<.01%     
==========================================
  Files         370      370              
  Lines       67268    67269       +1     
==========================================
+ Hits        56554    56558       +4     
+ Misses      10714    10711       -3

@codecov
Copy link

codecov bot commented Feb 25, 2019

Codecov Report

Merging #3624 into master will increase coverage by 0.16%.
The diff coverage is 100%.

@@            Coverage Diff             @@
##           master    #3624      +/-   ##
==========================================
+ Coverage   84.07%   84.24%   +0.16%     
==========================================
  Files         370      370              
  Lines       67268    67469     +201     
==========================================
+ Hits        56554    56836     +282     
+ Misses      10714    10633      -81

@janezd janezd merged commit 8186dd6 into biolab:master Feb 25, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants