corrected bug in decision tree algorithm to handle range checks properly