1. Learn
  2. /
  3. Courses
  4. /
  5. HR Analytics: Predicting Employee Churn in Python

Exercise

Splitting the tree

Given the Gini index that would result from splitting by either variable A or B, respectively, decide by which variable the tree should split next.

Instructions

100 XP
  • Check which Gini is lower.
  • If A has lower Gini, split by A, else, split by B.