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

DEPR: deprecate Series/DataFrame.to_dense/to_sparse #26557

Closed
jorisvandenbossche opened this issue May 29, 2019 · 0 comments · Fixed by #26684
Closed

DEPR: deprecate Series/DataFrame.to_dense/to_sparse #26557

jorisvandenbossche opened this issue May 29, 2019 · 0 comments · Fixed by #26684
Labels
Deprecate Functionality to remove in pandas good first issue Sparse Sparse Data Type
Milestone

Comments

@jorisvandenbossche
Copy link
Member

We should properly deprecate to_dense and to_sparse on Series and DataFrame.

Series.to_dense already is disfunctional (#25680), and DataFrame.to_dense can be replaced with DataFrame.sparse.to_dense().

And the to_sparse methods return a SparseSeries / SparseDataFrame, which are deprecated (and in that sense already show some deprecation warning, but this should be done properly with their own deprecation warning and doc update).
Those could in principle be replaced with a new DataFrame/Series.sparse.to_sparse method? (although you can already do astype('Sparse'))

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Deprecate Functionality to remove in pandas good first issue Sparse Sparse Data Type
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant