This takes a dataset and a split ID and generates two subsets of the data corresponding to a training set and a holdout.

split_data(data, split_id)

Arguments

data

dataframe

split_id

integer representing the split to construct

Value

Returns an R6 object HTEFold with three public fields:

  • train - The split to be used for training the plugin estimates

  • holdout - The split not used for training

  • in_holdout - A logical vector indicating for each unit whether they lie in the holdout.