SoftRandomForest (version 0.1.0)

SoftForestPredFeeder: Choosing the appropriate depth function.

Description

SoftForestPredFeeder is used inside the user interface function to choose the appropriate depth function since the SDT's depth are not generated dynamically.

Usage

SoftForestPredFeeder(trainresponse, train, test, num.features, ntry, depth)

Arguments

trainresponse

A vector of responses 0 and 1 for the training set with length equal to the number of observations in the training set.

train

A matrix or data frame consisting of all possible variables to attempt for the training set.

test

A matrix or data frame consisting of all possible variables to attempt for the test set.

num.features

The number of variables in the dataset to possibly try. The leftmost number of variables in the dataset are the variables chosen.

ntry

The number of variables from the num.features to attempt to split. This is useful for building random forests. For a standard tree, choose ntry = num.features.

depth

The number of the depth each SDT should be. Here this ends with \(2^{depth - 1}\) terminal nodes.

Value

The output from the chosen function.

Details

SoftForestPredDepth chooses the correct of five possible depths that has functioning code. Any invalid attempt returns an error.