Content
Lecture 2............................................................................................................................................1
Lecture 3............................................................................................................................................3
Lecture 4............................................................................................................................................5
Lecture 5............................................................................................................................................6
Lecture 6............................................................................................................................................7
Lecture 7............................................................................................................................................7
Lecture 8............................................................................................................................................7
Lecture 9............................................................................................................................................8
Lecture 10........................................................................................................................................10
Lecture 11........................................................................................................................................10
Lecture 12........................................................................................................................................12
Lecture 13........................................................................................................................................13
Lecture 14........................................................................................................................................15
Lecture 15........................................................................................................................................16
Lecture 16........................................................................................................................................18
Lecture 17 (guest lectures)..............................................................................................................19
Booking.com................................................................................................................................19
eScience center............................................................................................................................21
Lecture 2
Decision tree
- Split the set of instances in subsets such that the variation within each subset becomes
smaller
Entropy = degree of uncertainty
,First number means total classified here, second number means incorrectly classified ones of the
total
Exercise
What is tree depth? how many squares there are, 3
Would you further grow tree? yes, ‘young’ has 55 incorrectly classified out of 381. Further
growing could prove usefu
Confusion matrix and measures
Quality measures
Error
, - (FP + FN) / total
How many of the actual negative instances did the model identify?
Accuracy
- (TP + TN) / total
How many instances did the model classify correctly over all instances?
Precision
- TP / (TP + FP)
How many of the predicted positive instances are actually positive?
Recall
- TP / (TP + FN)
How many of the actual positive instances did the model identify?
F1 score
- 2 * (precision * recall) / (precision + recall)
A balance between precision and recall
Exercise
What setting would you choose for the tree size?
Answer between 10 and 20 are the best results, smaller tree is generally better so 10
Lecture 3
Overfitting
- The model is too specific for the data set used to learn the model and performs poorly on
new instances
- High variance
Underfitting
- The model is too general and does not exploit the data
- High bias
Lecture 2............................................................................................................................................1
Lecture 3............................................................................................................................................3
Lecture 4............................................................................................................................................5
Lecture 5............................................................................................................................................6
Lecture 6............................................................................................................................................7
Lecture 7............................................................................................................................................7
Lecture 8............................................................................................................................................7
Lecture 9............................................................................................................................................8
Lecture 10........................................................................................................................................10
Lecture 11........................................................................................................................................10
Lecture 12........................................................................................................................................12
Lecture 13........................................................................................................................................13
Lecture 14........................................................................................................................................15
Lecture 15........................................................................................................................................16
Lecture 16........................................................................................................................................18
Lecture 17 (guest lectures)..............................................................................................................19
Booking.com................................................................................................................................19
eScience center............................................................................................................................21
Lecture 2
Decision tree
- Split the set of instances in subsets such that the variation within each subset becomes
smaller
Entropy = degree of uncertainty
,First number means total classified here, second number means incorrectly classified ones of the
total
Exercise
What is tree depth? how many squares there are, 3
Would you further grow tree? yes, ‘young’ has 55 incorrectly classified out of 381. Further
growing could prove usefu
Confusion matrix and measures
Quality measures
Error
, - (FP + FN) / total
How many of the actual negative instances did the model identify?
Accuracy
- (TP + TN) / total
How many instances did the model classify correctly over all instances?
Precision
- TP / (TP + FP)
How many of the predicted positive instances are actually positive?
Recall
- TP / (TP + FN)
How many of the actual positive instances did the model identify?
F1 score
- 2 * (precision * recall) / (precision + recall)
A balance between precision and recall
Exercise
What setting would you choose for the tree size?
Answer between 10 and 20 are the best results, smaller tree is generally better so 10
Lecture 3
Overfitting
- The model is too specific for the data set used to learn the model and performs poorly on
new instances
- High variance
Underfitting
- The model is too general and does not exploit the data
- High bias