Realize Decision Tree algorithm using PYTHON.
Choose the "split attribute" of each node based on Information Gain (just like the famous ID3 algorithm).
Train a decision tree and store the tree in a dictionary form.
Test the algorithm using data in Table 4.1 in page 76, Table 4.2 in page 80 and Table 4.3 in page 84 of Machine Learning written by Prof. Zhou Zhihua.
Other data can be used to train the decision tree as well.
使用PYTHON实现决策树算法。
使用信息增益作为每个节点划分属性的选择准则(和著名的ID3决策树算法)相同。
训练一个决策树并且使用一个字典来存储这个决策树。
用周志华教授的《机器学习》76页表4.1,80页表4.2和84页表4.3的数据来测试算法效果。
也可以使用其他数据来运行该程序训练决策树。