Download Week 8-ppt - Monash University

Document related concepts

Cluster analysis wikipedia , lookup

Nonlinear dimensionality reduction wikipedia , lookup

Transcript
Intelligence Through Learning from Data
Monash University
Semester 1, March 2006
www.monash.edu.au
Lecture Outline
• Machine Learning – Yet another form of intelligent
software
– Learning for Data
• Data Mining – A real world application of learning
from data
– Data Mining Concepts
– Data Mining Techniques
– Data Mining Applications
www.monash.edu.au
2
Lecture Objectives
By the end of this lecture, you should:
• Understand the relationship between machine learning and
data mining
• Know the principles of learning from data and the various
techniques for learning from data
• Understand the real world applications of learning from
data
• Be able to distinguish between this form of intelligence in
software systems and other strategies such as software
agents, context-awareness, expert systems and knowledge
representation/deductive approaches
www.monash.edu.au
3
Machine Learning
www.monash.edu.au
4
Machine Learning
• Machine Learning is an area of Artificial Intelligence.
• It is concerned with programs that learn
• Data Mining uses machine learning for prediction and
classification
• Feedback on the correctness of a prediction combined
with examples and domain knowledge allow the
program to learn.
• Machine Learning is also used in speech recognition,
robot training, classification of astronomical structures
and game playing.
www.monash.edu.au
5
Machine Learning
• “A general law can never be verified by a finite
number of observations. It can, however, be
falsified by only one observation.”
Karl Popper
• The patterns that machine learning algorithms
find can never be definitive theories
• Any results discovered must to be tested for
statistical relevance
www.monash.edu.au
6
The Empirical Cycle
Analysis
Theory
Observation
Prediction
www.monash.edu.au
7
Concept Learning - 1
• Example: the concept of a wombat
–a learning algorithm could consider many animals
and be advised in each case whether it is a wombat or
not. From this a definition would be deduced.
• The definition is
–complete if it recognizes all instances of a concept (
in this case a wombat).
–consistent if it does not classify any negative
examples as falling under the concept.
www.monash.edu.au
8
Concept Learning - 2
• An incomplete definition is too narrow
and would not recognize some wombats.
• An inconsistent definition is too broad
and would classify some non-wombats as
wombats.
• A bad definition could be both
inconsistent and incomplete.
www.monash.edu.au
9
Hypothesis Characteristics - 1
• Classification Accuracy
–1 in a million wrong is better than 1 in 10
wrong.
• Transparency
–A person is able understand the hypothesis
generated. It is then much easier to take
action
www.monash.edu.au
10
Hypothesis Characteristics - 2
• Statistical Significance
–The hypothesis must perform better than the naïve
prediction. (Imagine if 80% of animals considered are
wombats and the theory is that all animals are
wombats then the theory is right 80% of the time! But
nothing has been learnt.)
• Information Content
– We look for a rich hypothesis. The more information
contained (while still being transparent) the more
understanding is gained and the easier it is to
formulate an action plan.
www.monash.edu.au
11
Complexity of Search Space
• Machine learning can be considered as a search problem. We
wish to find the correct hypothesis from among many.
–If there are only a few hypotheses we could try them all but if
there are an infinite number we need a better strategy.
–If we have a measure of the quality of the hypothesis we can
use that measure to select potential good hypotheses and
based on the selection try to improve the theories (hillclimbing search)
• Consider the metaphor of the kangaroo in the mist.
–This demonstrates that it is important to know the complexity
of the search space. Also that some pattern recognition
patterns are almost impossible to solve.
www.monash.edu.au
12
Learning as a Compression
• We have learnt something if we have an algorithm that
creates a description of the data that is shorter than the
original data set
• A knowledge representation is required that is
incrementally compressible and an algorithm that can
achieve that incremental compression
File-in
File-out
Algorithm
• The file-in could be a relation table and the file-out a
prediction or a suggested clustering
www.monash.edu.au
13
Data Mining
www.monash.edu.au
14
Introduction
• Motivation: Why data mining?
• What is data mining?
• Data Mining: On what kind of data?
• Data mining functionality
• Are all the patterns interesting?
• Classification of data mining systems
• Link to Data Warehousing
www.monash.edu.au
15
Motivation: “Necessity is the Mother of
Invention”
•
Data explosion problem
– Automated data collection tools and mature database
technology lead to tremendous amounts of data stored in
databases, data warehouses and other information repositories
•
We are drowning in data, but starving for knowledge!
•
Solution: Data warehousing and data mining
– Data warehousing and on-line analytical processing
– Extraction of interesting knowledge (rules, regularities,
patterns, constraints) from data in large databases
www.monash.edu.au
16
Evolution of Database Technology
• 1960s:
– Data collection, database creation, IMS and network DBMS
• 1970s:
– Relational data model, relational DBMS implementation
• 1980s:
– RDBMS, advanced data models (extended-relational, OO,
deductive, etc.) and application-oriented DBMS (spatial,
scientific, engineering, etc.)
• 1990s—2000s:
– Data mining and data warehousing, multimedia databases, and
Web databases
www.monash.edu.au
17
What Is Data Mining?
• Data mining (knowledge discovery in databases - KDD):
– Extraction of interesting (non-trivial, implicit, previously
unknown and potentially useful) information or patterns
from data in large databases
• Alternative names and their “inside stories”:
– Data mining: a misnomer?
– Knowledge discovery(mining) in databases (KDD),
knowledge extraction, data/pattern analysis, data
archeology, data dredging, information harvesting,
business intelligence, etc.
• What is not data mining?
– (Deductive) query processing.
– Expert systems or small ML/statistical programs
www.monash.edu.au
18
Episodes Database
Data Preparation
Association Discovery
Rules 1% support
If test A then test B
will occur in 62%
of cases
GP Database
Merge
Database
Segmentation
Segment 1 Segment 2
97 GPs
206 GPs
Score = 1.8 Score = 2.7
www.monash.edu.au
19
Why Data Mining? — Potential Applications
•
Database analysis and decision support
– Market analysis and management
> target marketing, customer relation management, market
basket analysis, cross selling, market segmentation
– Risk analysis and management
> Forecasting, customer retention, improved underwriting, quality
control, competitive analysis
– Fraud detection and management
•
Other Applications
– Text mining (news group, email, documents) and Web analysis.
– Intelligent query answering
www.monash.edu.au
20
Market Analysis and Management (1)
• Where are the data sources for analysis?
– Credit card transactions, loyalty cards, discount coupons,
customer complaint calls, plus (public) lifestyle studies
• Target marketing
– Find clusters of “model” customers who share the same
characteristics: interest, income level, spending habits, etc.
• Determine customer purchasing patterns over time
– Conversion of single to a joint bank account: marriage, etc.
• Cross-market analysis
– Associations/co-relations between product sales
– Prediction based on the association information
www.monash.edu.au
21
Market Analysis and Management (2)
• Customer profiling
– data mining can tell you what types of customers buy what
products (clustering or classification)
• Identifying customer requirements
– identifying the best products for different customers
– use prediction to find what factors will attract new customers
• Provides summary information
– various multidimensional summary reports
– statistical summary information (data central tendency and
variation)
www.monash.edu.au
22
Corporate Analysis and Risk
Management
• Finance planning and asset evaluation
– cash flow analysis and prediction
– contingent claim analysis to evaluate assets
– cross-sectional and time series analysis (financial-ratio, trend
analysis, etc.)
• Resource planning:
– summarize and compare the resources and spending
• Competition:
– monitor competitors and market directions
– group customers into classes and a class-based pricing
procedure
– set pricing strategy in a highly competitive market
www.monash.edu.au
23
Fraud Detection and Management (1)
• Applications
– widely used in health care, retail, credit card services,
telecommunications (phone card fraud), etc.
• Approach
– use historical data to build models of fraudulent behavior and
use data mining to help identify similar instances
• Examples
– auto insurance: detect a group of people who stage accidents
to collect on insurance
– money laundering: detect suspicious money transactions (US
Treasury's Financial Crimes Enforcement Network)
– medical insurance: detect professional patients and ring of
doctors and ring of references
www.monash.edu.au
24
Fraud Detection and Management (2)
• Detecting inappropriate medical treatment
– Health Insurance Commission identifies that in many cases
blanket screening tests might have been requested (can save
$$).
• Detecting telephone fraud
– Telephone call model: destination of the call, duration, time of
day or week. Analyze patterns that deviate from an expected
norm.
– British Telecom identified discrete groups of callers with
frequent intra-group calls, especially mobile phones, and broke
a multimillion dollar fraud.
• Retail
– Analysts estimate that 38% of retail shrink is due to dishonest
employees.
www.monash.edu.au
25
Other Applications
• Sports
– IBM Advanced Scout analyzed NBA game statistics (shots
blocked, assists, and fouls) to gain competitive advantage for
New York Knicks and Miami Heat
• Astronomy
– JPL and the Palomar Observatory discovered 22 quasars with
the help of data mining
• Internet Web Surf-Aid
– IBM Surf-Aid applies data mining algorithms to Web access
logs for market-related pages to discover customer
preference and behavior pages, analyzing effectiveness of
Web marketing, improving Web site organization, etc.
www.monash.edu.au
26
Data Mining: A KDD Process
– Data mining: the core
of knowledge
discovery process.
Pattern Evaluation
Data Mining
Task-relevant Data
Data Warehouse
Selection
Data Cleaning
Data Integration
Databases
www.monash.edu.au
27
The Process of Knowledge Discovery
Data
Cleaning &
Coding
selection Enrichment
-domain consistency
-de-duplication
-disambiguation
Data mining Reporting
- clustering
- segmentation
- prediction
Information
Requirement
Action
Feedback
Operational data
External data
The Knowledge Discovery in Databases (KDD) process (Adriens/Zantinge)
www.monash.edu.au
28
Steps of a KDD Process
•
•
•
•
•
•
•
•
•
Learning the application domain:
– relevant prior knowledge and goals of application
Creating a target data set: data selection
Data cleaning and preprocessing: (may take 60% of effort!)
Data reduction and transformation:
– Find useful features, dimensionality/variable reduction, invariant
representation.
Choosing functions of data mining
– summarization, classification, regression, association, clustering.
Choosing the mining algorithm(s)
Data mining: search for patterns of interest
Pattern evaluation and knowledge presentation
– visualization, transformation, removing redundant patterns, etc.
Use of discovered knowledge
www.monash.edu.au
29
Data Mining and Business Intelligence
Increasing potential
to support
business decisions
Making
Decisions
End User
Data Presentation
Visualization Techniques
Data Mining
Business
Analyst
Information Discovery
Data
Analyst
Data Exploration
Statistical Analysis, Querying and Reporting
Data Warehouses / Data Marts
OLAP, MDA
Data Sources
DBA
www.monash.edu.au
30
Paper, Files, Information Providers, Database Systems, OLTP
Architecture of a Typical Data Mining
System
Graphical user interface
Pattern evaluation
Data mining engine
Knowledge-base
Database or data
warehouse server
Data cleaning & data integration
Databases
Filtering
Data
Warehouse
www.monash.edu.au
31
Data Mining: On What Kind of Data?
•
•
•
•
Relational databases
Data warehouses
Transactional databases
Advanced DB and information repositories
–
–
–
–
–
–
Object-oriented and object-relational databases
Spatial databases
Time-series data and temporal data
Text databases and multimedia databases
Heterogeneous and legacy databases
WWW
www.monash.edu.au
32
Data Mining Techniques
• Various taxonomies exist. Berry & Linoff define 6 tasks
–Classification
–Estimation
–Prediction
–Clustering
–Description
–Affinity Grouping
• Cabena et al. define 4 operations(i.e. tasks)
–Predictive Modeling
–Database Segmentation
–Link Analysis
–Deviation Detection
www.monash.edu.au
33
Classification
• Classification involves considering the
features of some object then assigning it
it to some pre-defined class, for example:
–Spotting fraudulent insurance claims
–Which phone numbers are fax numbers
–Which customers are high-value
www.monash.edu.au
34
Estimation
• Estimation deals with numerically valued
outcomes rather than discrete categories
as occurs in classification.
–Estimating the number of children in a family
–Estimating family income
www.monash.edu.au
35
Prediction
• Essentially the same as classification and
estimation but involves future behaviour
• Historical data is used to build a model
explaining behaviour (outputs) for known inputs
• The model developed is then applied to current
inputs to predict future outputs
–Predict which customers will respond to a promotion
–Classifying loan applications
www.monash.edu.au
36
Clustering
• Clustering is also sometimes referred to as
segmentation (though this has other meanings
in other fields)
• In clustering there are no pre-defined classes.
Self-similarity is used to group records. The user
must attach meaning to the clusters formed
• Clustering often precedes some other data
mining task, for example:
–once customers are separated into clusters, a
promotion might be carried out based on market
basket analysis of the resulting cluster
www.monash.edu.au
37
Description
• A good description of data can provide
understanding of behaviour
• The description of the behaviour can
suggest an explanation for it as well
• Statistical measures can be useful in
describing data, as can techniques that
generate rules
www.monash.edu.au
38
Deviation Detection
• Records whose attributes deviate from the norm
by significant amounts are also called outliers
• Application areas include:
–fraud detection
–quality control
–tracing defects.
• Visualization techniques and statistical
techniques are useful in finding outliers
• A cluster which contains only a few records may
in fact represent outliers
www.monash.edu.au
39
Affinity Grouping
• Affinity grouping is also referred to as Market
Basket Analysis
• A common example is the discovery of which
items are frequently sold together at a
supermarket. If this is known, decisions can be
made about:
– arranging items on shelves
–which items should be promoted together
–which items should not simultaneously be discounted
www.monash.edu.au
40
Association Rule Mining
Rule Body
Confidence
When a customer buys a shirt, in 70% of cases,
he or she will also buy a tie!
We find this happens in 13.5% of all purchases.
Rule Head
Support
www.monash.edu.au
41
Association Rule Mining
• Some rules are useful: Unknown, unexpected and
indicative of some action to take.
• Some rules are trivial: Known by anyone familiar
with the business.
• Some rules are inexplicable: Seem to have no
explanation and do not suggest a course of action.
“The key to success in business is to know
something that nobody else knows”
Aristotle Onassis
www.monash.edu.au
42
Co-Occurrence Table
Customer
1
2
3
4
5
OJ
Cleaner
Milk
Cola
Detergent
Items
orange juice (OJ), cola
milk, orange juice, window cleaner
orange juice, detergent
orange juice, detergent, cola
window cleaner, cola
OJ Cleaner
4
1
1
2
1
1
2
1
2
0
Milk Cola Detergent
1
2
1
1
1
0
0
3
0
1
2
0
0
1
2
www.monash.edu.au
43
From the Co-Occurrence Table
• We can say that people who buys Orange Juice also
will buy Cola ( or detergent).
orange juice  cola
• This association rule is satisfied by 2 out of 5
customers ( 1 and 4) hence support is 2/5 = 40%
• However, there are three customers (1,3 and 4) have
purchased orange juice and hence the confidence of
the above rule is only 2/3 = 66.67%
• Question: Are support and confidence measures good
enough?
• The rule has one item (or attribute) on the left hand
side and the right hand side. How do you find rules
which has more than one items on the left hand side
(multi-attribute rule)
www.monash.edu.au
44
Support and Confidence
•
•
•
Support:
– Percentage of transactions from a transaction database that the
given rule satisfies.
– This can be taken as the probability P(X  Y) where X  Y
indicates that a transaction contains both X and Y, that is union
of item sets X and Y.
Confidence:
– Which assess the degree of certainty of the detected
association.
– This can be taken as the conditional probability P(Y|X), that is,
the probability that a transaction containing X also contains Y.
More formally
– Support (X  Y ) = P (X  Y)
– Confidence (X  Y) = P (Y|X)
www.monash.edu.au
45
What is a Rule?
If condition then result
Note:
If nappies and Thursday then beer
is usually better than (in the sense that it is more actionable)
If Thursday then nappies and beer
because it has just one item in the result
If a 3 way combination is the most common, then consider rules with
just 1 item in the result, e.g.
If A and B, then C
If A and C, then B
www.monash.edu.au
46
Data Mining Functionalities (2)
• Classification and Prediction
– Finding models (functions) that describe and distinguish
classes or concepts for future prediction
– E.g., classify countries based on climate, or classify cars based
on gas mileage
– Presentation: decision-tree, classification rule, neural network
– Prediction: Predict some unknown or missing numerical values
• Cluster analysis
– Class label is unknown: Group data to form new classes, e.g.,
cluster houses to find distribution patterns
– Clustering based on the principle: maximizing the intra-class
similarity and minimizing the interclass similarity
www.monash.edu.au
47
Data Mining Functionalities (3)
• Outlier analysis
– Outlier: a data object that does not comply with the general behavior
of the data
– It can be considered as noise or exception but is quite useful in fraud
detection, rare events analysis
• Trend and evolution analysis
– Trend and deviation: regression analysis
– Sequential pattern mining, periodicity analysis
– Similarity-based analysis
• Other pattern-directed or statistical analyses
www.monash.edu.au
48
Are All the “Discovered” Patterns Interesting?
•
A data mining system/query may generate thousands of patterns, not
all of them are interesting.
– Suggested approach: Human-centered, query-based, focused mining
•
Interestingness measures: A pattern is interesting if it is easily
understood by humans, valid on new or test data with some degree of
certainty, potentially useful, novel, or validates some hypothesis that a
user seeks to confirm
•
Objective vs. subjective interestingness measures:
– Objective: based on statistics and structures of patterns, e.g., support,
confidence, etc.
– Subjective: based on user’s belief in the data, e.g., unexpectedness,
novelty, actionability, etc.
www.monash.edu.au
49
Can We Find All and Only Interesting Patterns?
• Find all the interesting patterns: Completeness
– Can a data mining system find all the interesting patterns?
– Association vs. classification vs. clustering
• Search for only interesting patterns: Optimization
– Can a data mining system find only the interesting patterns?
– Approaches
> First general all the patterns and then filter out the uninteresting
ones.
> Generate only the interesting patterns—mining query optimization
www.monash.edu.au
50
Data Mining: Confluence of Multiple Disciplines
Database
Technology
Machine
Learning
Information
Science
Statistics
Data Mining
Visualization
Other
Disciplines
www.monash.edu.au
51
Data Mining: Classification Schemes
• General functionality
– Descriptive data mining
– Predictive data mining
• Different views, different classifications
– Kinds of databases to be mined
– Kinds of knowledge to be discovered
– Kinds of techniques utilized
– Kinds of applications adapted
www.monash.edu.au
52
A Multi-Dimensional View of Data Mining Classification
•
Databases to be mined
– Relational, transactional, object-oriented, object-relational,
active, spatial, time-series, text, multi-media, heterogeneous,
legacy, WWW, etc.
•
Knowledge to be mined
– Characterization, discrimination, association, classification,
clustering, trend, deviation and outlier analysis, etc.
– Multiple/integrated functions and mining at multiple levels
•
Techniques utilized
– Database-oriented, data warehouse (OLAP), machine
learning, statistics, visualization, neural network, etc.
•
Applications adapted
– Retail, telecommunication, banking, fraud analysis, DNA mining,
stock market analysis, Web mining, Weblog analysis, etc.
www.monash.edu.au
53
Data Mining and the Data Warehouse
• Organizations realized that they had large amounts of
data stored (especially of transactions) but it was not
easily accessible
• The data warehouse provides a convenient data source
for data mining. Some data cleaning has usually
occurred. It exists independently of the operational
systems
– Data is retrieved rather than updated
– Indexed for efficient retrieval
– Data will often cover 5 to 10 years
• A data warehouse is not a pre-requisite for data mining
www.monash.edu.au
54
Data Mining and OLAP
• Online Analytic Processing (OLAP)
• Tools that allow a powerful and efficient
representation of the data
• Makes use of a representation known as a cube
• A cube can be sliced and diced
• OLAP provide reporting with aggregation and
summary information but does not reveal
patterns, which is the purpose of data mining
www.monash.edu.au
55
Major Issues in Data Mining (1)
• Mining methodology and user interaction
– Mining different kinds of knowledge in databases
– Interactive mining of knowledge at multiple levels of abstraction
– Incorporation of background knowledge
– Data mining query languages and ad-hoc data mining
– Expression and visualization of data mining results
– Handling noise and incomplete data
– Pattern evaluation: the interestingness problem
• Performance and scalability
– Efficiency and scalability of data mining algorithms
– Parallel, distributed and incremental mining methods
www.monash.edu.au
56
Major Issues in Data Mining (2)
• Issues relating to the diversity of data types
– Handling relational and complex types of data
– Mining information from heterogeneous databases and
global information systems (WWW)
• Issues related to applications and social impacts
– Application of discovered knowledge
> Domain-specific data mining tools
> Intelligent query answering
> Process control and decision making
– Integration of the discovered knowledge with existing
knowledge: A knowledge fusion problem
– Protection of data security, integrity, and privacy
www.monash.edu.au
57
Summary
• Data mining: discovering interesting patterns from large
amounts of data
• A natural evolution of database technology, in great demand,
with wide applications
• A KDD process includes data cleaning, data integration, data
selection, transformation, data mining, pattern evaluation, and
knowledge presentation
• Mining can be performed in a variety of information repositories
• Data mining functionalities: characterization, discrimination,
association, classification, clustering, outlier and trend
analysis, etc.
• Classification of data mining systems
• Major issues in data mining
www.monash.edu.au
58
A Brief History of Data Mining Society
• 1989 IJCAI Workshop on Knowledge Discovery in Databases
(Piatetsky-Shapiro)
– Knowledge Discovery in Databases (G. Piatetsky-Shapiro and W. Frawley,
1991)
• 1991-1994 Workshops on Knowledge Discovery in Databases
– Advances in Knowledge Discovery and Data Mining (U. Fayyad, G.
Piatetsky-Shapiro, P. Smyth, and R. Uthurusamy, 1996)
• 1995-1998 International Conferences on Knowledge Discovery in
Databases and Data Mining (KDD’95-98)
– Journal of Data Mining and Knowledge Discovery (1997)
• 1998 ACM SIGKDD, SIGKDD’1999-2001 conferences, and
SIGKDD Explorations
• More conferences on data mining
– PAKDD, PKDD, SIAM-Data Mining, (IEEE) ICDM, etc.
www.monash.edu.au
59
Where to Find References?
• Data mining and KDD (SIGKDD member CDROM):
– Conference proceedings: KDD, and others, such as PKDD,
PAKDD, etc.
– Journal: Data Mining and Knowledge Discovery
• Database field (SIGMOD member CD ROM):
– Conference proceedings: ACM-SIGMOD, ACM-PODS, VLDB,
ICDE, EDBT, DASFAA
– Journals: ACM-TODS, J. ACM, IEEE-TKDE, JIIS, etc.
• AI and Machine Learning:
– Conference proceedings: Machine learning, AAAI, IJCAI, etc.
– Journals: Machine Learning, Artificial Intelligence, etc.
• Statistics:
– Conference proceedings: Joint Stat. Meeting, etc.
– Journals: Annals of statistics, etc.
• Visualization:
– Conference proceedings: CHI, etc.
– Journals: IEEE Trans. visualization and computer graphics, etc.
www.monash.edu.au
60
References
•
U. M. Fayyad, G. Piatetsky-Shapiro, P. Smyth, and R. Uthurusamy. Advances
in Knowledge Discovery and Data Mining. AAAI/MIT Press, 1996.
•
J. Han and M. Kamber. Data Mining: Concepts and Techniques. Morgan
Kaufmann, 2000.
•
T. Imielinski and H. Mannila. A database perspective on knowledge
discovery. Communications of ACM, 39:58-64, 1996.
•
G. Piatetsky-Shapiro, U. Fayyad, and P. Smith. From data mining to
knowledge discovery: An overview. In U.M. Fayyad, et al. (eds.), Advances
in Knowledge Discovery and Data Mining, 1-35. AAAI/MIT Press, 1996.
•
G. Piatetsky-Shapiro and W. J. Frawley. Knowledge Discovery in Databases.
AAAI/MIT Press, 1991.
www.monash.edu.au
61