views:

32

answers:

1

Hi there,
I am writing my own code for a decision tree. I need to decide on when to terminate the tree building process. I could think of limiting the height of the tree, but this seems trivial. Could anyone give me a better idea on how to implement my termination function.

Here in my tree building algorithm.

Thanks a lot.

+1  A: 

There is little context in your question, but I assume your are constructing a tree from a large set of data? In that case, a solution is in addition to a "LearnSet" to take a "StopSet" of examples and regularly verify your decision making process on this StopSet. If quality decreases, this is an indication that your are overtraing on the LearnSet.

I deliberately use "StopSet" and not "TestSet" because after this you should apply your decision tree on the TestSet to assess the real quality.

Emile
`If quality decreases, this is an indication that your are overtraing on the LearnSet`: while that is true it may very well mean that the decision tree was not trained enough. Which brings us back to the OPs question...
Eugen Constantin Dinca