convert all columns to float pandas

df["data"] = df["data"].astype(float)

Here is what the above code is Doing:
1. We’re creating a new column called “data” and setting it equal to the “data” column.
2. We’re setting the data type of the “data” column to float.
3. We’re setting the data type of the “data” column to int.
4. We’re setting the data type of the “data” column to str.
5. We’re setting the data type of the “data” column to bool.
6. We’re setting the data type of the “data” column to datetime.
7. We’re setting the data type of the “data” column to timedelta.
8. We’re setting the data type of the “data” column to category.