Learn R Programming

DynForest (version 1.1.3)

rf_shape_para: Paralleled random survival Forest using multivariate longitudinal endogenous covariates

Description

Paralleled random survival Forest using multivariate longitudinal endogenous covariates

Usage

rf_shape_para(
  Longitudinal = NULL,
  Numeric = NULL,
  Factor = NULL,
  timeVar = NULL,
  Y,
  mtry,
  ntree,
  ncores,
  nsplit_option = "quantile",
  nodesize = 1,
  minsplit = 2,
  cause = 1,
  seed = 1234,
  verbose = TRUE
)

Arguments

Longitudinal

A list of longitudinal predictors which should contain: X a dataframe with one row for repeated measurement and as many columns as markers; id is the vector of the identifiers for the repeated measurements contained in X; time is the vector of the measurement times contained in X.

Numeric

A list of numeric predictors which should contain: X a dataframe with as many columns as numeric predictors; id is the vector of the identifiers for each individual.

Factor

A list of categorical predictors which should contain: X a dataframe with as many columns as categorical predictors; id is the vector of the identifiers for each individual.

timeVar

A character indicating the name of time variable

Y

A list of output which should contain: type defines the nature of the output, can be "surv", "numeric" or "factor"; Y is the outcome variable; id is the vector of the identifiers for each individuals, they should be the same as the identifiers of the inputs.

mtry

Number of candidate variables randomly drawn at each node of the trees. This parameter should be tuned by minimizing the OOB error. Default is NULL.

ntree

Number of trees to grow. Default value set to 200.

ncores

Number of cores used to grow trees in parallel. Default value is the number of cores of the computer-1.

nsplit_option

A character indicates how the values are chosen to build the two groups for the splitting rule (only for continuous predictors). Values are chosen using deciles (nsplit_option="quantile") or randomly (nsplit_option="sample"). Default value is "quantile".

nodesize

Minimal number of subjects required in both child nodes to split. Cannot be smaller than 1.

minsplit

(Only with survival outcome) Minimal number of events required to split the node. Cannot be smaller than 2.

cause

(Only with competing events) Number indicates the event of interest.

seed

Seed to replicate results

verbose

A logical controlling the function progress. Default is TRUE