create_model: Train an RFSLAM model

View source: R/rf_functions_p2.R

create_modelR Documentation

Train an RFSLAM model

Description

create_model trains a RFSLAM model using the given user parameter values

Usage

create_model(
  modeling_df,
  target,
  id_col,
  risk_time_col,
  patient_count_col = "int.n",
  time_col,
  ntree = 100,
  nodedepth = NULL,
  nsplit = 10
)

Arguments

modeling_df

dataframe containing data for modeling

target

name of the target variable column

id_col

name of the column with the patient id's

risk_time_col

name of the column with the risk time values

patient_count_col

name of the column with the patient counts

ntree

number of trees for random forest

nodedepth

the node depth for random forest

nsplit

the nsplit parameter for random forest

Value

the RF-SLAM model, the predicted risk values (uncalibrated) together in a list that you can index into using the model and preds arguments


dshenker/RFSLAM documentation built on Sept. 18, 2022, 3:26 a.m.