Skip to content

DOC: DataFrame.reindex improve summary and return type #34584

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

Closed
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions pandas/core/generic.py
Original file line number Diff line number Diff line change
Expand Up @@ -4241,9 +4241,9 @@ def reindex(self: FrameOrSeries, *args, **kwargs) -> FrameOrSeries:
"""
Conform %(klass)s to new index with optional filling logic.

Places NA/NaN in locations having no value in the previous index. A new object
is produced unless the new index is equivalent to the current one and
``copy=False``.
Places NA/NaN in locations having no value in the previous index. A new
DataFrame with an additional index is generated subject to customization
Copy link
Contributor

Choose a reason for hiding this comment

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

this is generic, so could be Series/DataFrame

with parameters.

Parameters
----------
Expand Down Expand Up @@ -4286,7 +4286,7 @@ def reindex(self: FrameOrSeries, *args, **kwargs) -> FrameOrSeries:

Returns
-------
%(klass)s with changed index.
%(klass)s with 2 indices.
Copy link
Contributor

Choose a reason for hiding this comment

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

this is not correct, only 1 index is changed.


See Also
--------
Expand Down