Skip to content

DOC: Official "Cheat Sheet" shows as_type() method, correct signature is astype() #61523

Closed
@brchristian

Description

@brchristian

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://github.com/pandas-dev/pandas/blob/main/doc/cheatsheet/Pandas_Cheat_Sheet.pdf

Documentation problem

The third page of the official "Cheat Sheet" at https://github.com/pandas-dev/pandas/blob/main/doc/cheatsheet/Pandas_Cheat_Sheet.pdf has a section called "Changing Type". It lists df.as_type(type), however no such method exists; the correct method should be df.astype(type).

Suggested fix for documentation

The fix is straightforward: replace as_type with astype.

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions