Splits data into training, validation, and testing sets and optionally applies normalization to predictors and response.
Usage
preprocessing.data(
x,
y,
n.knots,
testing_ratio = 0.1,
valid_ratio = 0.1,
normalize = FALSE
)Arguments
- x
Numeric matrix of covariates.
- y
Numeric vector or matrix of response values.
- n.knots
Integer. Number of spline knots.
- testing_ratio
Proportion of data allocated to testing.
- valid_ratio
Proportion of training data allocated to validation.
- normalize
Logical. If TRUE, standardizes predictors and rescales response.
