Skip to content

Control split direction #51

@fisherj-2212

Description

@fisherj-2212

I'm attempting to use rpart to build a classification tree. My response variable is a vector of zeroes and ones, representing my two classes. My predictor variables are all continuous numeric values. The goal is a tree that shows the best splits to isolate class 1, and make it distinct from all the class 0 samples.

I'm trying to see if there's a way to control the splitting direction. What I'm aiming for is a tree that prioritises 'greater than' splits i.e. thresholding such that my target class (class 1) has value greater than the threshold. This is to avoid 'negative selection' where class 1 is characterised by the tree as having low values of the thresholding variables. Do you have any advice for how to implement this behaviour?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions