Skip to content
Cleaning Data in Python
  • AI Chat
  • Code
  • Report
  • Cleaning Data in Python

    Run the hidden code cell below to import the data used in this course.

    Hidden code

    Take Notes

    Add notes about the concepts you've learned and code cells with code you want to keep.

    Add your notes here

    Run cancelled
    # Add your code snippets here

    Explore Datasets

    Use the DataFrames imported in the first cell to explore the data and practice your skills!

    • For each DataFrame, inspect the data types of each column and, where needed, clean and convert columns into the correct data type. You should also rename any columns to have more descriptive titles.
    • Identify and remove all the duplicate rows in ride_sharing.
    • Inspect the unique values of all the columns in airlines and clean any inconsistencies.
    • For the airlines DataFrame, create a new column called International from dest_region, where values representing US regions map to False and all other regions map to True.
    • The banking DataFrame contains out of date ages. Update the Age column using today's date and the birth_date column.
    • Clean the restaurants_new DataFrame so that it better matches the categories in the city and type column of the restaurants DataFrame. Afterward, given typos in restaurant names, use record linkage to generate possible pairs of rows between restaurants and restaurants_new using criteria you think is best.