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

Series.fillna #317

Merged
merged 6 commits into from
May 14, 2019
Merged

Series.fillna #317

merged 6 commits into from
May 14, 2019

Conversation

garawalid
Copy link
Contributor

databricks/koalas/series.py Outdated Show resolved Hide resolved
ks = koalas.from_pandas(ps)

self.assert_eq(ks.fillna(0), ps.fillna(0))
self.assert_eq(ks.fillna({'x': 0}), ps.fillna(0))
Copy link
Contributor Author

Choose a reason for hiding this comment

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

It turns out that Pandas.Series.fillna supports neither Series nor dict as value.
Koalas.Series.fillna does!

@codecov-io
Copy link

codecov-io commented May 14, 2019

Codecov Report

Merging #317 into master will increase coverage by 0.24%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #317      +/-   ##
==========================================
+ Coverage   93.81%   94.06%   +0.24%     
==========================================
  Files          34       35       +1     
  Lines        3315     3454     +139     
==========================================
+ Hits         3110     3249     +139     
  Misses        205      205
Impacted Files Coverage Δ
databricks/koalas/missing/series.py 100% <ø> (ø) ⬆️
databricks/koalas/series.py 92.92% <100%> (+0.61%) ⬆️
databricks/koalas/tests/test_series.py 100% <100%> (ø) ⬆️
databricks/koalas/exceptions.py 78.12% <0%> (-1.29%) ⬇️
databricks/koalas/missing/frame.py 100% <0%> (ø) ⬆️
databricks/koalas/tests/test_series_conversion.py 100% <0%> (ø) ⬆️
...tabricks/koalas/tests/test_dataframe_conversion.py 100% <0%> (ø) ⬆️
databricks/koalas/tests/test_dataframe.py 100% <0%> (ø) ⬆️
... and 3 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 56843fc...1691dab. Read the comment docs.

databricks/koalas/series.py Outdated Show resolved Hide resolved

Parameters
----------
value : scalar, dict, Series
Copy link
Contributor

Choose a reason for hiding this comment

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

i think we should just follow pandas here and drop dict/Series. This is a Series, so there's only one column really.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@rxin
Pandas doc says that it supports dict & Series.
But I think the doc is a copy paste of DataFrame.fillna.

Anyway, we can remove them from the docstring.

@garawalid
Copy link
Contributor Author

@rxin I left only scalar as values.

@rxin rxin merged commit 9b1e616 into databricks:master May 14, 2019
@rxin
Copy link
Contributor

rxin commented May 14, 2019

Thanks. I've merged this. This will be available as part of release 0.4.

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.

3 participants