...

/

Introduction to Decision Trees

Introduction to Decision Trees

Get introduced to decision trees.

The uses of decision tree models are given below:

  • They are used for both classification and regression (CART).

  • They answer sequential questions and send us down a specific tree route to find the outcomes class.

  • They behave like “if this, then that” conditions ultimately yield a particular result.

Context

Let’s say someone wants to practice soccer. Before they decide to go out, they have a few questions about the weather.

Decisions Table

Outlook

Windy

Humidity

Playing

Sunny

T

High

No

Overcast

T

Normal

Yes

Rainy

T

Normal

Yes

Rainy

T

High

No

Sunny

F

Normal

Yes

.

.

.

.

.

.

.

.

.

.

.

.

As the decision table goes on, we can visualize whether or not to play based on the weather.

The decision tree above has the following features:

  • Root node: The starting point of the tree—for example, "Outlook".

  • Branches: Arrow lines connecting nodes, showing the flow from question to answer segments of the trees that connect the nodes.

  • Leaf node: ...

Access this course and 1400+ top-rated courses and projects.