Giter Site home page Giter Site logo

lab-data-cleaning-and-wrangling's Introduction

logo_ironhack_blue 7

Lab | Data cleaning and wrangling

For this lab, we will be using the Marketing Customer Value Analysis database from before. Feel free to build on top of your previous notebooks, since there could be overlap with variable names.

Instructions

This lab will focus on data cleaning and wrangling, this is a crucial step in the EDA process.

  1. Remove the outliers in the dataset using one of the methods we've discussed by defining a function and applying it to the dataframe.
  2. Create a copy of the dataframe for the data wrangling.
  3. Normalize the continuous variables.
  4. Encode the categorical variables
  5. Transform the time variables (day, week and month) to integers.
  6. Since the model will only accept numerical data, check and make sure that every column is numerical, if some are not, change it using encoding.

Hint for Categorical Variables

  • Use either encoding or get_dummies to deal with the categorical variables (example below):
data["coverage"] = data["coverage"].map({"Basic" : 0, "Extended" : 1, "Premium" : 2})
# given that column "coverage" in the dataframe "data" has three categories:
# "basic", "extended", and "premium" and values are to be represented in the same order.

lab-data-cleaning-and-wrangling's People

Contributors

gleeful-penguin avatar sandrabosk avatar tonyhathuc avatar

Stargazers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.