Skip to contents

Grows the tree by repeatedly calling best_global_ci_split() at each node, so every split is chosen by directly maximizing concentration-index gain over candidate variables and candidate split points. The returned node is a partykit node and can be wrapped by partykit::party().

Usage

.build_ci_tree(data, y, wt, vars, ctrl, ci_fun, type = "CI")

Arguments

data

Data frame of predictor variables.

y

Two-column numeric matrix with rank and outcome.

wt

Non-negative case weights.

vars

Integer positions of predictor variables considered for splitting.

ctrl

Normalized control list from .ci_tree_normalize_control().

ci_fun

Concentration-index function created by ci_factory().

type

Concentration-index type used when control$split_engine is "cpp".

Value

A list with node, the root partykit::partynode(), and fitted, an integer vector mapping training rows to terminal node ids.