Skip to main content

Lesson 2.5 – Basic Data Cleaning

Lesson 2.5 – Basic Data Cleaning

Clean data is essential for accurate calculations, sorting, filtering, and analysis. Even small issues—extra spaces, inconsistent capitalization, or unwanted characters— can cause formulas to fail or produce incorrect results. In this lesson, you will learn simple but powerful tools to clean data quickly using Excel functions.


1. Why Data Cleaning Matters

Raw data often contains problems such as:

  • Extra spaces before or after text
  • Inconsistent capitalization
  • Non-printable characters from imported files
  • Mixed formats (text that looks like numbers)

Cleaning data ensures consistency and prevents errors in formulas and analysis.


2. TRIM – Remove Extra Spaces

TRIM(text) removes extra spaces from text, leaving only single spaces between words.

Example:

  • Original: “ Product A ”
  • Formula: =TRIM(A1)
  • Result: “Product A”

TRIM is essential when working with imported or manually typed data.


3. CLEAN – Remove Non‑Printable Characters

CLEAN(text) removes hidden characters that often appear in data imported from PDFs, websites, or external systems.

Example:

  • Original: “Product A□” (invisible character)
  • Formula: =CLEAN(A1)
  • Result: “Product A”

CLEAN is especially useful when data looks normal but behaves incorrectly.


4. PROPER – Capitalize Text Correctly

PROPER(text) converts text to “Title Case,” capitalizing the first letter of each word.

Example:

  • Original: “john SMITH”
  • Formula: =PROPER(A1)
  • Result: “John Smith”

Use PROPER for names, titles, and labels.


5. Combining Cleaning Functions

You can combine TRIM, CLEAN, and PROPER to fix multiple issues at once.

Example:

=PROPER(TRIM(CLEAN(A1)))

This formula:

  • removes non‑printable characters
  • removes extra spaces
  • applies proper capitalization

6. Converting Text Numbers to Real Numbers

Sometimes numbers are stored as text and cannot be used in formulas.

Fix:

  • Use Value: =VALUE(A1)
  • Or multiply by 1: =A1*1
  • Or add zero: =A1+0

Excel then converts the text into a real numeric value.


7. Practical Exercise

Practice data cleaning with the following steps:

  1. Create a worksheet named Lesson_2_5_Practice.
  2. In column A, enter five messy text values (extra spaces, mixed case, symbols).
  3. Use TRIM to remove extra spaces.
  4. Use CLEAN to remove non‑printable characters.
  5. Use PROPER to fix capitalization.
  6. Combine all three functions in a single formula.
  7. Convert text numbers into real numbers using VALUE.

Next Lesson

Module 3 – Essential Formulas and Functions

Comments

Popular posts from this blog

Alfred Marshall – The Father of Modern Microeconomics

  Welcome back to the blog! Today we explore the life and legacy of Alfred Marshall (1842–1924) , the British economist who laid the foundations of modern microeconomics . His landmark book, Principles of Economics (1890), introduced core concepts like supply and demand , elasticity , and market equilibrium — ideas that continue to shape how we understand economics today. Who Was Alfred Marshall? Alfred Marshall was a professor at the University of Cambridge and a key figure in the development of neoclassical economics . He believed economics should be rigorous, mathematical, and practical , focusing on real-world issues like prices, wages, and consumer behavior. Marshall also emphasized that economics is ultimately about improving human well-being. Key Contributions 1. Supply and Demand Analysis Marshall was the first to clearly present supply and demand as intersecting curves on a graph. He showed how prices are determined by both what consumers are willing to pay (dem...

Unlocking South America's Data Potential: Trends, Challenges, and Strategic Opportunities for 2025

  Introduction South America is entering a pivotal phase in its digital and economic transformation. With countries like Brazil, Mexico, and Argentina investing heavily in data infrastructure, analytics, and digital governance, the region presents both challenges and opportunities for professionals working in Business Intelligence (BI), Data Analysis, and IT Project Management. This post explores the key data trends shaping South America in 2025, backed by insights from the World Bank, OECD, and Statista. It’s designed for analysts, project managers, and decision-makers who want to understand the region’s evolving landscape and how to position themselves for impact. 1. Economic Outlook: A Region in Transition According to the World Bank’s Global Economic Prospects 2025 , Latin America is expected to experience slower growth compared to global averages, with GDP expansion constrained by trade tensions and policy uncertainty. Brazil and Mexico remain the largest economies, with proj...

Kickstart Your SQL Journey with Our Step-by-Step Tutorial Series

  Welcome to Data Analyst BI! If you’ve ever felt overwhelmed by rows, columns, and cryptic error messages when trying to write your first SQL query, you’re in the right place. Today we’re launching a comprehensive SQL tutorial series crafted specifically for beginners. Whether you’re just starting your data career, pivoting from another field, or simply curious about how analysts slice and dice data, these lessons will guide you from day zero to confident query builder. In each installment, you’ll find clear explanations, annotated examples, and hands-on exercises. By the end of this series, you’ll be able to: Write efficient SQL queries to retrieve and transform data Combine multiple tables to uncover relationships Insert, update, and delete records safely Design robust database schemas with keys and indexes Optimize performance for large datasets Ready to master SQL in a structured, step-by-step way? Let’s explore the full roadmap ahead. Wh...