cs570 introduction to data mining classification and
play

CS570 Introduction to Data Mining Classification and Prediction - PowerPoint PPT Presentation

CS570 Introduction to Data Mining Classification and Prediction Partial slide credits: Han and Kamber Tan,Steinbach, Kumar 1 1 Overview


  1. CS570 Introduction to Data Mining Classification and Prediction Partial slide credits: Han and Kamber Tan,Steinbach, Kumar 1 1

  2. ����������������������������� Overview � Classification algorithms and methods � � Decision tree induction � Bayesian classification � kNN classification � Support Vector Machines (SVM) � Neural Networks Regression � Evaluation and measures � Ensemble methods � Data Mining: Concepts and Techniques 2 2

  3. �������������������� �������������������� Skin Color Size Flesh Conclusion Hairy Brown Large Hard safe Hairy Hairy Green Green Large Large Hard Hard Safe Safe Smooth Red Large Soft Dangerous Hairy Green Large Soft Safe Smooth Small Hard Dangerous Red … Li Xiong Data Mining: Concepts and Techniques 3 3 3

  4. ����������������������������� � Classification � predicts categorical class labels � constructs a model based on the training set and uses it in classifying new data � Prediction (Regression) � models continuous8valued functions, i.e., predicts models continuous8valued functions, i.e., predicts unknown or missing values � Typical applications � Credit approval � Target marketing � Medical diagnosis � Fraud detection Data Mining: Concepts and Techniques 4 4

  5. ��������� ��������������� Name Age Income … Credit Clark 35 High … Excellent Milton 38 High … Excellent Neo 25 Medium … Fair … … … … … … … … … … Classification rule: � � If age = “31...40” and income = high then credit_rating = excellent Future customers � � Paul: age = 35, income = high ⇒ excellent credit rating � John: age = 20, income = medium ⇒ fair credit rating Data Mining: Concepts and Techniques 5 5

  6. �������������������� !����������� Model construction: describing a set of predetermined classes � � Each tuple/sample is assumed to belong to a predefined class, as determined by the class label attribute � The set of tuples used for model construction is training set � The model is represented as classification rules, decision trees, or mathematical formulae Model usage: for classifying future or unknown objects Model usage: for classifying future or unknown objects � � � Estimate accuracy of the model � The known label of test sample is compared with the classified result from the model � Accuracy rate is the percentage of test set samples that are correctly classified by the model � Test set is independent of training set, otherwise over8fitting will occur � If the accuracy is acceptable, use the model to classify data tuples whose class labels are not known Data Mining: Concepts and Techniques 6 6

  7. ��������"#$%������������������� �������������� �������� ���������� ���� ���������� ������� Data Mining: Concepts and Techniques 7 7

  8. ��������"&$%�'������(��������������������� ���������� ������� ������� ����������� ���� Data Mining: Concepts and Techniques 8 8

  9. !��������������'������������)������� � Supervised learning (classification) � Supervision: The training data (observations, measurements, etc.) are accompanied by labels indicating the class of the observations indicating the class of the observations � New data is classified based on the training set � Unsupervised learning (clustering) � The class labels of training data is unknown � Given a set of measurements, observations, etc. with the aim of establishing the existence of classes or clusters in the data Data Mining: Concepts and Techniques 9 9

  10. ������%������������������������������(��� � Accuracy � Speed � time to construct the model (training time) � time to use the model (classification/prediction time) � Robustness: handling noise and missing values � Scalability: efficiency in disk8resident databases Scalability: efficiency in disk8resident databases � Interpretability � understanding and insight provided by the model � Other measures, e.g., goodness of rules, decision tree size or compactness of classification rules Data Mining: Concepts and Techniques 10 10

  11. ����������������������������� Overview � Classification algorithms and methods � � Decision tree � Bayesian classification � kNN classification � Support Vector Machines (SVM) � Others Evaluation and measures � Ensemble methods � Data Mining: Concepts and Techniques 11 11

  12. ���������*������ age income student credit_rating buys_computer <=30 high no fair no <=30 high no excellent no 31�40 high no fair yes >40 medium no fair yes >40 >40 low low yes yes fair fair yes yes >40 low yes excellent no 31�40 low yes excellent yes <=30 medium no fair no <=30 low yes fair yes >40 medium yes fair yes <=30 medium yes excellent yes 31�40 medium no excellent yes 31�40 high yes fair yes >40 medium no excellent no Data Mining: Concepts and Techniques 12 12

  13. ��*�����������������+ ,�-�.��������/ ���� ���� �������� ������ ��� �������� �������������� ��� ��������� ���� �� ��� ��� �� ��� Data Mining: Concepts and Techniques 13 13

  14. �������(������*���������������������� ID3 (Iterative Dichotomiser), C4.5, by Quinlan � CART (Classification and Regression Trees) � Basic algorithm (a greedy algorithm) 8 tree is constructed with top8 � down recursive partitioning At start, all the training examples are at the root � � A test attribute is selected that “best” separate the data into � A test attribute is selected that “best” separate the data into partitions � Samples are partitioned recursively based on selected attributes Conditions for stopping partitioning � � All samples for a given node belong to the same class � There are no remaining attributes for further partitioning – majority voting is employed for classifying the leaf � There are no samples left Data Mining: Concepts and Techniques 14 14

  15. �����,����!����������������� � Idea: select attribute that partition samples into homogeneous groups � Measures � Information gain (ID3) � Gain ratio (C4.5) Gain ratio (C4.5) � Gini index (CART) Data Mining: Concepts and Techniques 15 15

  16. �����,����!����������������%� ������������0����"�*1$ Select the attribute with the highest information gain � Let p i be the probability that an arbitrary tuple in D belongs to class C i , � estimated by |C i , D |/|D| Information (entropy) needed to classify a tuple in D (before split): � � ∑ = − ���� � � � � ��� � � � � � � � = = � � � Information needed (after using A to split D into v partitions) to � � = ∑ � classify D: � × ���� � � � ���� � � � � � � = � � Information gain – difference between before and after splitting on � attribute A = − ������� ������� ���� ��� � Data Mining: Concepts and Techniques 16 16

Recommend


More recommend