RFEAT: Random Forest + Efficiency Analysis Trees

View source: R/rfEAT.R

RFEATR Documentation

Random Forest + Efficiency Analysis Trees

Description

This function builds m individual Efficiency Analysis Trees in a forest structure.

Usage

RFEAT(data, x, y, numStop = 5, m = 50, s_mtry = "BRM", na.rm = TRUE)

Arguments

data

data.frame or matrix containing the variables in the model.

x

Column input indexes in data.

y

Column output indexes in data.

numStop

Minimum number of observations in a node for a split to be attempted.

m

Number of trees to be built.

s_mtry

Number of variables randomly sampled as candidates at each split. The available options are:

  • "BRM": in / 3

  • "DEA1": (t.obs / 2) - out

  • "DEA2": (t.obs / 3) - out

  • "DEA3": t.obs - 2 * out

  • "DEA4": min(t.obs / out, (t.obs / 3) - out)

  • Any integer

na.rm

logical. If TRUE, NA rows are omitted.

Value

A RFEAT object containing:

  • data

    • df: data frame containing the variables in the model.

    • x: input indexes in data.

    • y: output indexes in data.

    • input_names: input variable names.

    • output_names: output variable names.

    • row_names: rownames in data.

  • control

    • numStop: numStop hyperparameter value.

    • m: m hyperparameter value.

    • s_mtry: s_mtry hyperparameter value.

    • na.rm: na.rm hyperparameter value.

  • forest: list containing the individual EAT models.

  • error: Out-of-Bag error at the forest.

  • OOB: list containing Out-of-Bag set for each tree.

Examples


simulated <- X2Y2.sim(N = 50, border = 0.1)

RFmodel <- RFEAT(data = simulated, x = c(1,2), y = c(3, 4), numStop = 5,
                  m = 50, s_mtry = "BRM", na.rm = TRUE)



eat documentation built on Jan. 10, 2023, 5:13 p.m.