Motivation
We are rich in data but poor in knowledge. Businesses, hospitals, banks and the web produce terabytes of data every day. Data mining is needed to find useful, previously unknown patterns in it, because no person can read so much data. It is also called knowledge mining from data.
What Is Data Mining
Data mining is the process of discovering interesting patterns and knowledge from large amounts of data using methods from statistics, machine learning and databases. A pattern is interesting if it is valid on new data, useful, novel and easy to understand.
KDD Process
Knowledge Discovery in Databases (KDD) is the whole process, and data mining is one step in it:
- Data cleaning: remove noise and inconsistent data.
- Data integration: combine data from several sources.
- Data selection: retrieve the data relevant to the task.
- Data transformation: convert it to forms suitable for mining (aggregation, normalisation).
- Data mining: apply methods to extract patterns.
- Pattern evaluation: identify the truly interesting patterns.
- Knowledge presentation: show results using visualisation.
Data Mining Functionalities
- Characterisation and discrimination: summarise a class or compare classes.
- Association and correlation: find items that occur together (bread and butter).
- Classification: assign objects to known classes using a model.
- Prediction and regression: estimate numeric values.
- Clustering: group similar objects without known classes.
- Outlier (anomaly) analysis: find unusual objects such as frauds.
- Evolution analysis: study trends over time.
Issues and Applications
Issues include mining methodology (handling noisy and varied data), performance (scalability and efficiency), user interaction (interactive mining), and privacy and social impact. Applications include market basket analysis, fraud detection, medical diagnosis, customer segmentation, recommendation systems and weather forecasting.
Definition: KDD. Knowledge Discovery in Databases, the overall process of turning raw data into useful knowledge through cleaning, integration, selection, transformation, mining, evaluation and presentation.
Table 1.4: Data mining functionalities
| Functionality | Question answered | Example |
|---|---|---|
| Association | What occurs together? | Bread and butter |
| Classification | Which class does it belong to? | Loan safe or risky |
| Clustering | Which objects are alike? | Customer segments |
| Regression | What numeric value? | Next month sales |
| Outlier analysis | What is unusual? | Credit card fraud |
Example 1.4: Records through the KDD pipeline
Problem: A retailer has 12,000 raw transaction records. Cleaning removes 600 duplicates and 400 records with missing values. Selection keeps the 60 percent belonging to active customers. Transformation then summarises every 3 records into one customer row. How many rows reach the mining step?
Solution:
- After cleaning: 12,000 - 600 - 400 = 11,000 records.
- After selection: 60 percent of 11,000 = 6,600 records.
- After transformation: 6,600 / 3 = 2,200 customer rows.
Result: 2,200 rows are given to the mining algorithm, about 18 percent of the original records.
raw = 12000
cleaned = raw - 600 - 400
selected = int(cleaned * 0.60)
rows = selected // 3
print("After cleaning :", cleaned)
print("After selection :", selected)
print("After transformation:", rows)
print("Share of raw data :", round(rows / raw * 100, 1), "%")
Output
After cleaning : 11000
After selection : 6600
After transformation: 2200
Share of raw data : 18.3 %
Common mistakes
- Treating data mining and KDD as exactly the same; mining is one step of KDD.
- Skipping data cleaning and expecting good patterns from poor data.
- Accepting every pattern found; most are not interesting.
- Ignoring privacy when mining personal data.
Key takeaways
- KDD has seven steps; data mining is the fifth.
- Functionalities: association, classification, prediction, clustering, outliers.
- A pattern must be valid, novel, useful and understandable.
- Issues: methodology, performance, user interaction, privacy.
Practice questions
- What is KDD?
- Name two data mining functionalities.
- Why is data cleaning done first?
Answers to the practice questions
- The overall process of discovering knowledge from data, with data mining as one step.
- Classification and clustering (also association and outlier analysis).
- Noisy or inconsistent data gives wrong patterns.
Sources
- Official BCA syllabus Data Warehousing and Mining, course code 25BCA406DS03, Unit I
