implemented apply_decision_tree, now need to do helper functions