get_best_tree {FFTrees} | R Documentation |
Select the best tree (from current set of FFTs)
Description
get_best_tree
selects (looks up and identifies) the best tree (as an integer)
from the set (or “fan”) of FFTs contained in the current FFTrees
object x
,
an existing type of data
('train' or 'test'), and
a goal
for which corresponding statistics are available
in the designated data
type (in x$trees$stats
).
Usage
get_best_tree(x, data, goal, my.goal.max = TRUE)
Arguments
x |
An |
data |
The type of data to consider (as character: either 'train' or 'test'). |
goal |
A goal (as character) to be maximized or minimized when selecting a tree
from an existing |
my.goal.max |
Default direction for user-defined |
Details
Importantly, get_best_tree
only identifies and selects the 'tree' identifier
(as an integer) from the set of existing trees with known statistics,
rather than creating new trees or computing new cue thresholds.
More specifically, goal
is used for identifying and selecting the 'tree'
identifier (as an integer) of the best FFT from an existing set of FFTs, but not for
computing new cue thresholds (see goal.threshold
and fftrees_cuerank()
) or
creating new trees (see goal.chase
and fftrees_ranktrees()
).
Value
An integer denoting the tree
that maximizes/minimizes goal
in data
.
See Also
FFTrees
for creating FFTs from and applying them to data.
Other utility functions:
get_exit_type()
,
get_fft_df()