3 Data Mining
3 Data Mining
PaDern
Evalua;on
◦ Data
mining:
the
core
of
knowledge
discovery
process.
Data
Mining
Task-‐relevant Data
Data Cleaning
Data Integra;on
Databases
13
Data Mining Tasks
● Prediction Methods
– Use some variables to predict unknown or
future values of other variables. Earthquakes
Volcano Eruptions
Stock Market Crash
Weather Forecast
● Description Methods
– Find human-interpretable patterns that
describe the data.
Land Description
Gene Description
Lifestyle Description
Demographic Description
Data Mining Tasks...
● Classification [Predictive]
● Clustering [Descriptive]
● Association Rule Discovery [Descriptive]
● Sequential Pattern Discovery [Descriptive]
● Regression [Predictive]
● Deviation Detection [Predictive]
Classification: Definition
Set
Set Classifier
Model Contruction
Classification: Application 1
● Direct Marketing
– Goal: Reduce cost of mailing by targeting a set of
consumers likely to buy a new cell-phone product.
– Approach:
u Use the data for a similar product introduced before.
u We know which customers decided to buy and which
decided otherwise. This {buy, don’t buy} decision forms the
class attribute.
u Collectvarious demographic, lifestyle, and company-
interaction related information about all such customers.
– Type of business, where they stay, how much they earn, etc.
u Use
this information as input attributes to learn a classifier
model.
Classification: Application 2
● Fraud Detection
– Goal: Predict fraudulent cases in credit card
transactions.
– Approach:
u Usecredit card transactions and the information on its
account-holder as attributes.
– When does a customer buy, what does he buy, how often he pays on
time, etc
u Label past transactions as fraud or fair transactions. This
forms the class attribute.
u Learn a model for the class of the transactions.
● Customer Attrition/Churn:
– Goal: To predict whether a customer is likely to
be lost to a competitor.
– Approach:
u Use detailed record of transactions with each of the
past and present customers, to find attributes.
– How often the customer calls, where he calls, what time-of-the
day he calls most, his financial status, marital status, etc.
u Label the customers as loyal or disloyal.
u Find a model for loyalty.
Classification: Application 4
● Baseline
● Naïve Bayes
● Knn
● Neural Networks
● Decision Trees
Classification: Quality Measures
Late
Data Size:
• 72 million stars, 20 million galaxies
• Object Catalog: 9 GB
• Image Database: 150 GB
Clustering Definition
● Market Segmentation:
– Goal: subdivide a market into distinct subsets of
customers where any subset may conceivably be
selected as a market target to be reached with a
distinct marketing mix.
– Approach:
u Collect different attributes of customers based on their
geographical and lifestyle related information.
u Find clusters of similar customers.
● Document Clustering:
– Goal: To find groups of documents that are
similar to each other based on the important
terms appearing in them.
– Approach: To identify frequently occurring
terms in each document. Form a similarity
measure based on the frequencies of different
terms. Use it to cluster.
– Gain: Information Retrieval can utilize the
clusters to relate a new document or search
term to clustered documents.
Illustrating Document Clustering
National 273 36
1
Applied-Matl-DOW N,Bay-Net work-Down,3-COM-DOWN,
Cabletron-Sys-DOWN,CISCO-DOWN,HP-DOWN,
DSC-Co mm-DOW N,INTEL-DOWN,LSI-Logic-DOWN,
Micron-Tech-DOWN,Texas-Inst-Down,Tellabs-Inc-Down,
Technology1-DOWN
Natl-Semiconduct-DOWN,Oracl-DOWN,SGI-DOW N,
Sun-DOW N
2
Apple-Co mp-DOW N,Autodesk-DOWN,DEC-DOWN,
ADV-M icro-Device-DOWN,Andrew-Corp-DOWN,
Co mputer-Assoc-DOWN,Circuit-City-DOWN,
Technology2-DOWN
Co mpaq-DOWN, EM C-Corp-DOWN, Gen-Inst-DOWN,
Motorola-DOW N,Microsoft-DOWN,Scientific-Atl-DOWN
3
Fannie-Mae-DOWN,Fed-Ho me-Loan-DOW N,
MBNA-Corp -DOWN,Morgan-Stanley-DOWN Financial-DOWN
4
Baker-Hughes-UP,Dresser-Inds-UP,Halliburton-HLD-UP,
Louisiana-Land-UP,Phillips-Petro-UP,Unocal-UP, Oil-UP
Schlu mberger-UP
Association Rule Discovery: Definition
● Inventory Management:
– Goal: A consumer appliance repair company wants to
anticipate the nature of repairs on its consumer
products and keep the service vehicles equipped with
right parts to reduce on number of visits to consumer
households.
– Approach: Process the data on tools and parts
required in previous repairs at different consumer
locations and discover the co-occurrence patterns.
Basic Concepts: Frequent Patterns
and Association Rules
Transaction-id Items bought
● Itemset X = {x1, …, xk}
10 A, B, D
● Find all the rules X à Y with minimum
20 A, C, D
support and confidence
30 A, D, E
– support, s, probability that a
40 B, E, F
50 B, C, D, E, F
transaction contains X ∪ Y
– confidence, c, conditional
Customer Customer probability that a transaction
buys both buys diaper having X also contains Y
Let supmin = 50%, confmin = 50%
Freq. Pat.: {A:3, B:3, D:4, E:3, AD:3}
Association rules:
Customer
A à D (60%, 100%)
buys beer D à A (60%, 75%)
Regression
Typical network traffic at University level may reach over 100 million connections per day
Anomaly/Outlier Detection
● What are anomalies/outliers?
– The set of data points that are considerably
different than the remainder of the data
● Variants of Anomaly/Outlier Detection
Problems
– Given a database D, find all the data points x ∈ D
with anomaly scores greater than some threshold
t
● Applications:
– Credit card fraud detection, telecommunication
fraud detection, network intrusion detection, fault
detection
Importance of Anomaly Detection
● Challenges
– How many outliers are there in the data?
– Method is unsupervised
uValidation can be quite challenging (just like for
clustering)
– Finding needle in a haystack
● Working assumption:
– There are considerably more “normal”
observations than “abnormal” observations
(outliers/anomalies) in the data
Anomaly Detection Schemes
● General Steps
– Build a profile of the “normal” behavior
u Profile can be patterns or summary statistics for the overall population
– Use the “normal” profile to detect anomalies
u Anomalies are observations whose characteristics
differ significantly from the normal profile
Continuous Query
Results
Multiple streams
Stream Query
Processor
Scratch Space
(Main memory and/or Disk)
Challenges of Stream Data Processing
● Multiple, continuous, rapid, time-varying, ordered streams
● Main memory computations
● Queries are often continuous
– Evaluated continuously as stream data arrives
– Answer updated over time
http://usefulsocialmedia.com/customer-insight/social-mining-part-1-how-big-data-transforming-
customer-insights
Challenges of Data Mining
● Scalability
● Dimensionality
● Complex and Heterogeneous Data
● Data Quality
● Data Ownership and Distribution
● Privacy Preservation
● Streaming Data
END
Exercise
1
● Name
the
following
data
mining
techniques:
● A
rule
in
the
form
of
“if
this
then
that”
associates
events
in
a
database.
● The
process
of
learning
to
dis:nguish
and
discriminate
between
different
input
pa=erns
using
supervised
training
algorithm.
● The
process
of
grouping
similar
input
pa=erns
together
using
an
unsupervised
training
algorithm
● The
technique
determines
a
mathema:cal
equa:on
that
minimizes
some
measure
of
the
error
between
the
predic:on
and
the
actual
data
● Also
know
as
anomaly
or
outlier
detec:on,
this
technique
seeks
to
iden:fy
items,
events
or
observa:ons
which
do
not
conform
to
an
expected
pa=ern
or
other
items
in
a
dataset
Exercise
2
● What
is
the
difference
between
classifica:on
and
clustering
in
a
data
mining
environment?
● Describe
the
followings:
– Data
Stream
Mining
– Social
Mining
How
can
you
connect
the
two
concepts
above.
● Draw
the
Knowledge
Discovery
Process
● What
is
Customer
Rela:onship
Management
(CRM)?