Skip to content

DOC: name in Index.to_frame is claimed to default to index.name #63191

@cmp0xff

Description

@cmp0xff

Pandas version checks

  • I have checked that the issue still exists on the latest versions of the docs on main here

Location of the documentation

https://pandas.pydata.org/docs/dev/reference/api/pandas.Index.to_frame.html

Documentation problem

The actual default value is lib.no_default, but the docstring says name : object, defaults to index.name

Suggested fix for documentation

Change to something like name : Hashable, defaults to lib.no_default and move self.name to the next line, in the description. (object to hashable if the name is required to be a hashable)

Metadata

Metadata

Assignees

No one assigned

    Labels

    DocsNeeds TriageIssue that has not been reviewed by a pandas team member

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions