Learn R Programming

PEAXAI (version 0.1.0)

train_PEAXAI: Training a Classification Machine Learning Model

Description

This function trains a set of models and selects best hyperparameters for each of them.

Usage

train_PEAXAI(data, method, parameters, trControl, metric_priority, seed)

Value

It returns a list with the chosen model.

Arguments

data

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

method

Parameters for controlling the training process (from the 'caret' package).

parameters

A list of selected machine learning models and their hyperparameters.

trControl

A list of selected machine learning learning.

metric_priority

A string specifying the summary metric for classification to select the optimal model. Default includes "Balanced_Accuracy" due to (normally) unbalanced data.

seed

Integer. Seed for reproducibility.