Skip to content

DOC: to_datetime works real differently on DataFrames vs other datatypes #41676

Closed
@nielsbom

Description

@nielsbom

Location of the documentation

Documentation problem

The to_datetime method does something wildly different on strings or Series vs DataFrames. This caught me by surprise and I think it would help if the documentation reflected this more clearly.

Suggested fix for documentation

Something along the lines of:

For most datatypes given to the to_datetime method it creates datetime objects out of strings. If to_datetime is given a dataframe it does something quite different: it combines columns that contain year, month and day information into datetime objects.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions