A Beginner’s Guide to Converting Numerical Data to Categorical: Binning and Binarization
Author(s): Souradip Pal
Originally published on Towards AI.
This member-only story is on us. Upgrade to access all of Medium.
Imagine sifting through rows of data in a spreadsheet packed with numbers that look impressive at first glance. But when you try to analyze them, the digits feel like a maze, hard to interpret and even harder to draw conclusions from. Now, picture the same dataset, but this time, the numerical values have been grouped into tidy categories, making patterns jump out at you. It’s like watching a blurry image come into focus. Sounds better, right?
Source: Image by the AuthorThat’s exactly what converting numerical data into categorical data can do for you! In today’s post, we’ll dive into two game-changing techniques: Binning and Binarization, perfect for scenarios like those faced with datasets such as Google Playstore data, where categories — like the number of app downloads — are more telling than raw numbers.
By the end, you’ll know how to wrangle numerical data into meaningful categories with easy-to-follow code examples. Let’s get started, shall we?
First, let’s understand why you’d want to turn your perfectly good numerical data into categorical values.
Let’s take an example from the Google Playstore dataset. You have a column that tells you the number of times an… Read the full blog for free on Medium.
Join thousands of data leaders on the AI newsletter. Join over 80,000 subscribers and keep up to date with the latest developments in AI. From research to projects and ideas. If you are building an AI startup, an AI-related product, or a service, we invite you to consider becoming a sponsor.
Published via Towards AI