[scikit-learn] Decision trees with only pure leaves
pranavashok at gmail.com
Wed Aug 8 05:41:27 EDT 2018
I am trying to use scikit-learn for building decision trees representing
fully defined many-to-one functions. i.e. f(x1, x2, ..., xn) = f(x1', x2',
..., xn') if and only if x1 = x1', x2 = x2' and so on. In such a scenario,
it seems clear that it is possible to construct trees which have pure
leaves as long as min_samples_split = 2 and I am not setting any other
parameters which might stop the splitting. My question is whether the
decision tree builder in scikit-learn can indeed give me a perfect
representation, i.e where all leaf nodes are pure. This would imply that
tree.predict(x) = f(x).
Thanks and best regards.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the scikit-learn