Docsity

Decision Trees - Data Base Management System - Lecture Slides, Slides of Database Management Systems (DBMS)

Toggle sidebar
bg1
Decision Trees &
Supervised Learning
Docsity.com
pf3
pf4
pf5
pf8
pf9
pfa
pfd
pfe
pff
pf12
pf13

Partial preview of the text

Download Decision Trees - Data Base Management System - Lecture Slides and more Slides Database Management Systems (DBMS) in PDF only on Docsity!

Decision Trees &

Supervised Learning

Supervised Learning

Supervised learning is also called

classification or inductive learning. This is

similar to human learning from past

experiences to gain new knowledge in order

to improve our ability to perform real world

tasks. However, since machines do not have

“experiences,” machines learn from data that

represent past experiences.

What’s the Goal?

• Have the computer determine some function that

knows the result given some input data.

• This function is called the classification model.

• The data used to determine the function is called

training data.

• We can test our function using test data.^ This will

tell us how accurate our classification model is.

• One way to generate the classification model is a

Decision Tree.

What is a decision

tree?

• A decision tree is a decision support tool

that uses a tree-like graph or model of

decisions and their possible consequences,

including a chance event outcomes,

resource costs, and utility.

Use a Decision Tree

Step Through the Tree to Solve the

Problem

Our Experience

• Using the table from the previous slides we

want to determine some rules like this:

• Own_house = true, => Answer:Yes

• Own_house = false, Has_Job = true, =>

Answer:Yes

• Own_house = false, Has_Job = false, =>

Answer: No

BuildTree(DataSet, Out)

  • If all the output values are the same in DataSet, return a leaf node that says “predict this unique output”
  • If all the input values are the same, return a leaf node that says “predict the majority output”
  • Else find attribute X with highest Info Gain
  • Suppose X has N distinct values:
    • Create and return a non-leaf node with X children
      • the ith child should be built using: BuildTree(DS, Output). Where DS consists of all those records in DataSet for which X =ith distinct value of X

An Example

What’s Next?

• Run through a test data set and see how

accurate your tree is

TL;DR

• Supervised learning is trying to teach a machine

some thing by using existing data with known answers.

• Decision Trees are a way to classify existing data in

a way that we can predict future results.

• Construct DT’s from datasets using recursion.

• Test your DT against some test Data

• Profit!?!?