Machine Learning Engineer
Module 1 · Scientific Python (NumPy, Pandas) · Lesson 1 of 1
Module overview — Scientific Python (NumPy, Pandas)
Module overview — Scientific Python (NumPy, Pandas) Goal : Load, explore and clean a dataset with NumPy and Pandas before handing it to a model. Study time : Durée d'étude : 5 h Prerequisites : Bases de Python : variables, listes, dictionnaires et fonctions Running thread : Inês, in Lisbonne. Inês is a data analyst at an online shop in Lisbon that takes payments by MB WAY and by bank card. Her manager hands her two files: an export of payments and a three-month sales file, full of empty cells and duplicated rows. Before thinking about a model, she has to load them, understand them and clean them, keeping a trace of every decision. Lesson plan : 1. Getting started with a Jupyter notebook and loading a first CSV 2. NumPy and Pandas on a real dataset 3. Cleaning a sales dataset What you will be able to do : - Load a CSV file into a Pandas table and read its shape, types and missing values - Filter rows with a boolean mask and aggregate the results by group - Compute the percentage of missing values and the number of exact duplicates in a dataset - Write a cleaning plan that justifies every deletion and every fill End-of-module questions (Answer in writing, with figures.) : 1. In your exercise, how many rows remain after removing exact duplicates? Give the number. 2. What percentage of missing values does the price column carry, and which replacement value did you compute? 3. What are, in order, the four inspection commands you run on an unknown file? 4. What is the shape of your table before and after cleaning? Give the two pairs of numbers. Module deliverables : - Your five-step cleaning plan, with the three calculations - The data sheet of your project, opened in your notebook - The four inspection commands written with the question each one answers
Free preview, no account needed — the rest of this module and the following modules unlock after enrolling.
Convinced? Enroll to unlock the full course.
See pricing