Standardizes selected numeric columns using z-score or robust (median/MAD) methods. Binary columns (0/1) are left unchanged.
standardize_continuous(
DT,
cols,
method = c("zscore", "robust"),
center = TRUE,
scale = TRUE
)A list with components:
The standardized data.table.
A list of scaling parameters for each column.
A data.table or data.frame.
Character vector of column names to standardize.
Character; either "zscore" or "robust".
Logical; whether to center the data.
Logical; whether to scale the data.