create_config: Create rtemis configuration file

View source: R/config.R

create_configR Documentation

Create rtemis configuration file

Description

Defines a complete predictive modeling pipeline and saves it as a JSON file.

Usage

create_config(
  data_path,
  target = NULL,
  binclass_posid = 1,
  alg = "lightgbm",
  train.params = NULL,
  inner.resampling = setup.resample(resampler = "cv", n.resamples = 5),
  outer.resampling = setup.resample(resampler = "cv", n.resamples = 10),
  config.path = "rtemis-config.json",
  model.outdir = NULL,
  allow.overwrite = FALSE,
  verbose = TRUE
)

Arguments

data_path

Character: Path to data file. Can be any file recognized by read, commonly CSV, Excel, or RDS.

target

Character: Name of the target variable in the data. If not specified, the last column of data will be used.

binclass_posid

Integer: Position of the positive class in a binary classification problem.

alg

Character: Algorithm to use. Any of select_learn().

train.params

List: Parameters for the training algorithm.

inner.resampling

List: Resampling method for the inner loop, i.e. hyperparameter tuning, a.k.a. model selection. Set using setup.resample

outer.resampling

List: Resampling method for the outer loop, i.e. testing. Set using setup.resample

config.path

Character: Path to save configuration file.

model.outdir

Character: Directory to save trained model and associated files. If NULL, the directory of config.path will be used.

allow.overwrite

Logical: If TRUE, overwrite existing config file.

verbose

Logical: If TRUE, print messages

Value

config as list, invisibly.

Author(s)

EDG


egenn/rtemis documentation built on Dec. 17, 2024, 6:16 p.m.