top of page
Inaugurated by IN-SPACe
ISRO Registered Space Tutor

S8-SA2-0188

What is Data Cleaning in Mathematics?

Grade Level:

Class 8

AI/ML, Data Science, Research, Journalism, Law, any domain requiring critical thinking

Definition
What is it?

Data Cleaning in Mathematics is the process of finding and fixing errors, inconsistencies, and missing values in a dataset. It makes sure the data is accurate, complete, and ready to be used for analysis or making decisions.

Simple Example
Quick Example

Imagine you have a list of marks for your Class 8 science project. Some students have marks like '85', some have 'eighty-five', and one has '-10' (which is impossible!). Data cleaning means changing 'eighty-five' to '85' and removing or correcting the '-10' entry.

Worked Example
Step-by-Step

Let's clean a small dataset of daily chai prices (in Rupees) from a local shop: [15, 12, 15, 10, 'ten', 13, 150, 12, 14, MISSING].

Step 1: Identify incorrect data types. 'ten' is text, not a number.
---Step 2: Convert 'ten' to its numeric value. 'ten' becomes 10.
---Step 3: Identify outliers (values that are too high or too low). 150 seems very high for a chai price, likely a typo (maybe 15.0 or just 15).
---Step 4: Correct the outlier. Assume 150 was meant to be 15.0 or 15. Change 150 to 15.
---Step 5: Identify missing values. 'MISSING' needs to be handled.
---Step 6: Handle missing values. For this small set, we can replace 'MISSING' with the average of the other prices, or the most frequent price (mode). The mode is 15.
---Step 7: The cleaned data is: [15, 12, 15, 10, 10, 13, 15, 12, 14, 15].

Answer: The cleaned chai prices are [15, 12, 15, 10, 10, 13, 15, 12, 14, 15].

Why It Matters

Data cleaning is super important because bad data leads to bad decisions! From predicting cricket match outcomes to ensuring fair prices on e-commerce apps or even helping doctors diagnose diseases, clean data is the foundation. People working in Data Science, AI/ML, and Research rely on clean data every day.

Common Mistakes

MISTAKE: Ignoring missing values and just calculating averages or sums with them. | CORRECTION: Always decide how to handle missing data – either remove the entry, fill it with an average, or a specific value.

MISTAKE: Assuming all data is correct and directly starting analysis. | CORRECTION: Always check your data for errors, typos, and strange values before doing any calculations or drawing conclusions.

MISTAKE: Deleting all data entries that have any error, even small ones. | CORRECTION: Try to correct errors first if possible (like changing '85rupees' to '85'). Only delete entries if they are completely unusable or too many are wrong.

Practice Questions
Try It Yourself

QUESTION: A survey asked students their age: [12, 13, 'twelve', 14, 11, 120, 13]. What needs to be cleaned here? | ANSWER: 'twelve' needs to be converted to 12. '120' is an impossible age and needs to be corrected or removed (likely a typo for 12 or 13).

QUESTION: Your phone's step tracker recorded daily steps: [5000, 6200, 5500, 'Error', 6000, 5800]. How would you clean 'Error'? (Give one method) | ANSWER: Replace 'Error' with the average of the other values (5000+6200+5500+6000+5800)/5 = 5700. So 'Error' becomes 5700.

QUESTION: A small shop's daily sales (in Rupees) are: [100, 150, 90, 200, '2hundred', -50, 120, MISSING]. Clean this data, explaining each step. | ANSWER: Step 1: '2hundred' becomes 200. Step 2: -50 is an impossible sale, remove it or treat as 0. Let's remove it. Step 3: 'MISSING' can be filled with the average of the remaining values (100+150+90+200+200+120)/6 = 860/6 approx 143.33. Cleaned data: [100, 150, 90, 200, 200, 120, 143.33].

MCQ
Quick Quiz

Which of the following is NOT a common task in data cleaning?

Correcting misspelled words

Filling in missing information

Finding and removing duplicate entries

Creating colorful charts and graphs

The Correct Answer Is:

D

Data cleaning focuses on improving data quality. Creating charts and graphs is part of data visualization or analysis, which happens AFTER the data is clean.

Real World Connection
In the Real World

When you use a food delivery app like Zomato or Swiggy, the restaurant ratings and menu prices you see are based on clean data. If a restaurant's rating was accidentally entered as '1000' instead of '4.5', data cleaning would fix it, ensuring you get accurate information to choose your next meal.

Key Vocabulary
Key Terms

Dataset: A collection of related data | Inconsistency: When data doesn't match or follow a pattern | Outlier: A data point that is very different from other data points | Missing Value: A blank or absent piece of data | Data Quality: How accurate, complete, and reliable data is

What's Next
What to Learn Next

Great job learning about Data Cleaning! Next, you can explore 'Data Analysis'. Once data is clean, data analysis helps us find patterns and insights, which is the exciting part of using data to understand the world better.

bottom of page