DoOneHotEncoding: DoOneHotEncoding

DoOneHotEncodingR Documentation

DoOneHotEncoding

Description

This function will take specified column names and append them as one hot encoded variables

Usage

DoOneHotEncoding(
  MODEL_DATA,
  COLS_TO_ENCODE,
  DROP_ORIGINAL_COLS = FALSE,
  DROP_UNUSED_LEVELS = FALSE,
  DEBUG = TRUE
)

Arguments

MODEL_DATA

The processed dataset that will be used in the predictive model

COLS_TO_ENCODE

The column names containing character values that need to be encoded

DROP_ORIGINAL_COLS

Remove the original character variable

DROP_UNUSED_LEVELS

Drop any levels that are missing (should be FALSE)

DEBUG

If TRUE, the function will run in debug mode

Value

returns the originak data table with all the new features appended to the dataset

Author(s)

Abraham Mathew

See Also

Other Modeling Functions: RunAllModels(), mae(), rmse()


abmathewks/GoodeR documentation built on June 12, 2025, 1:48 a.m.