pandas types

pandas types (dtype) determine how each column is stored and processed: int64, float64, object or string, bool, datetime64, category. An incorrect type, such as a date read as text, distorts calculations and sorting. You check with dtypes and convert with astype or to_datetime.

Example

df["date"] = pd.to_datetime(df["date"])

Related concepts

The whole glossary