Re: why are there two different trees for the same data set
Date: February 21, 2022 04:23PM
There are different algorithms to build decision trees. A typical algorithm for building decision trees will for example build a tree from the top to the bottom, node by node. To decide which attribute to use in a node, the algorithm will use some criteria to compare the attributes.
There exists various criteria like the GINI, information gain, etc.
For example, the ID3 algorithm will use the entropy, while C4.5 will use the GINI measure. If two algorithms dont use the same criteria to select attributes and build trees, then the result can be different.
Besides, there can be other techniques use by some algorithm like to prune the trees etc.
I am not sure what is used by RandomForest and J.48, as I did not read these papers recently, but it is likely different So it is quite normal that they dont have the same output.