Exercise: Cleaning Auto MPG Dataset

This exercise will test a simple way to start investigating potential outliers.

We'll cover the following

Detect outliers #

In this exercise, we will use the same data frame as read in from the Reading Data exercise.

We will then create an additional function outlier_detection that takes a data frame df and returns 2 numbers in a list:

  • The 90th percentile for every column
  • The 10th percentile for every column

Try to implement the function below. Feel free to view the solution, after giving it a few shots. Good Luck!

Get hands-on with 1200+ tech skills courses.