fixed a bug in regression, there is still a bug in regression tree