Skip to contents

Returns a structured S3 object summarising the CTA descendant family. All values are read from stored fields - no refitting or recomputation is performed.

Usage

# S3 method for class 'cta_family'
summary(object, ...)

Arguments

object

A cta_family from cta_descendant_family.

...

Unused; included for S3 compatibility.

Value

summary.cta_family returns a list of class c("cta_family_summary", "list") with fields:

n_members

Integer number of family members.

min_d_idx

Integer index of the feasible member with minimum D; NA_integer_ if no feasible member exists.

terminated

Logical; always TRUE for a completed chain.

termination_reason

Character: one of "no_tree", "max_steps", "no_next_mindenom".

has_weights

Logical; TRUE when any family member used case weights.

table

A data.frame from cta_family_table.

Examples

data(mtcars)
X <- mtcars[, c("cyl", "disp", "hp", "wt")]
y <- as.integer(mtcars$am)
fam <- suppressMessages(
  cta_descendant_family(X, y, start_mindenom = 1L, mc_iter = 200L,
                        mc_seed = 42L, loo = "off")
)
s <- summary(fam)
print(s)
#> CTA descendant family
#>   members: 4  |  termination: no_tree  |  min-D index: 1
#>  index MINDENOM  status no_tree strata min_terminal_denom next_mindenom
#>      1        1   stump   FALSE      2                 14            15
#>      2       15   stump   FALSE      2                 15            16
#>      3       16   stump   FALSE      2                 16            17
#>      4       17 no_tree    TRUE     NA                 NA            NA
#>       ESS has_weights         D selected_min_d
#>  81.78138       FALSE 0.4455446           TRUE
#>  76.51822       FALSE 0.6137566          FALSE
#>  71.25506       FALSE 0.8068182          FALSE
#>        NA       FALSE        NA          FALSE
print(fam)
#> CTA descendant family
#>   members: 4  |  termination: no_tree  |  min-D index: 1
#>  index MINDENOM  status no_tree strata min_terminal_denom next_mindenom
#>      1        1   stump   FALSE      2                 14            15
#>      2       15   stump   FALSE      2                 15            16
#>      3       16   stump   FALSE      2                 16            17
#>      4       17 no_tree    TRUE     NA                 NA            NA
#>       ESS has_weights         D selected_min_d
#>  81.78138       FALSE 0.4455446           TRUE
#>  76.51822       FALSE 0.6137566          FALSE
#>  71.25506       FALSE 0.8068182          FALSE
#>        NA       FALSE        NA          FALSE