vt.subgroups {aVirtualTwins}R Documentation

Visualize subgroups

Description

Function which uses VT.tree intern functions. Package rpart.plot must be loaded. See VT.tree for details.

Usage

vt.subgroups(vt.trees, only.leaf = T, only.fav = T, tables = F,
  verbose = F, compete = F)

Arguments

vt.trees

VT.tree object. Or return of vt.tree function. Can be a list.

only.leaf

logical to select only leaf of trees. TRUE is default.

only.fav

logical select only favorable subgroups (meaning with favorable label of the tree). TRUE is default.

tables

set to TRUE if tables of incidence must be shown. FALSE is default.

verbose

print infos during computation. FALSE is default.

compete

print competitors rules thanks to competitors computation of the tree

Value

data.frame of rules

Examples

data(sepsis)
vt.o <- vt.data(sepsis, "survival", "THERAPY", TRUE)
# inside model :
vt.f <- vt.forest("one", vt.o)
# use classification tree
vt.tr <- vt.tree("class", vt.f, threshold = c(0.01, 0.05))
# show subgroups
subgroups <- vt.subgroups(vt.tr)
# change options you'll be surprised !
subgroups <- vt.subgroups(vt.tr, verbose = TRUE, tables = TRUE)


[Package aVirtualTwins version 1.0.1 Index]