Search code examples
classificationdata-miningweka

different tree for the same data set


I am working on Pima Indians Diabetes Database in Weka. I noticed that for decision tree J48 the tree is smaller as compared to the Random Tree. I am unable to understand why it is like this? Thank you.


Solution

  • Though they both are decision trees, they employ different algorithms for constructing the tree, which will (most likely) give you a different outcome:

    • J48 prunes the tree by default after it built its tree (Wikipedia).
    • RandomTree (when using default parameters) inspects a maximum of log2(num_attributes) attributes for generating splits.