Another part of tidying data involves transforming existing data into another presentation. This may be needed for the following reasons:
Values are not in the correct units
Values are qualitative and need to be converted to appropriate numeric values
There is extraneous data that either wastes memory and processing time, or can affect results simply by being included
To address these situations, we can take one or more of the following actions:
We have already seen how to delete rows and columns with several techniques, so we will not reiterate those here. We will cover the facilities provided by pandas for mapping, replacing, and applying functions to transform data based upon its content.