Question: Compulsory Task 1 In this compulsory task, you will clean the country column and parse the date _ measured column in the store _ income
Compulsory Task
In this compulsory task, you will clean the country column and parse the datemeasured column in the storeincomedatatask.csv file. Use the examples given in datacleaningexample.ipynb to guide you.
Complete the following in storeincometask.ipynb:
Load storeincomedatatask.csv
Take a look at all the unique values in the "country" column. Then, convert
the column entries to lowercase and remove any trailing white spaces.
Clean up the country column so that there are three distinct countries.
Create a new column called daysago in the DataFrame that is a copy of
the datemeasured column but instead shows a number that represents the number of days ago that it was measured. Note that the current date can be obtained using datetime.date.today
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
