DataSplit: partition of data (train-test-split)

View source: R/create_folds_and_data_split.R

DataSplitR Documentation

partition of data (train-test-split)

Description

partition of data (train-test-split)

Usage

DataSplit(y, TrainRatio = 0.75, regression = TRUE, shuffle = FALSE, seed = 1)

Arguments

y

is a numeric vector (response variable)

TrainRatio

is the percentage of train-data after the partition

regression

is a boolean (TRUE, FALSE) indicating if it's a regression or classification task

shuffle

is a boolean (TRUE, FALSE) indicating if the data should be shuffled or not (by default 5 times)

seed

an integer specifying the random seed

Value

a list of indices (train-test)

Examples


## Not run: 

data(iris)

y = X[, 1]

split = DataSplit(y, TrainRatio = 0.75, regression = FALSE, shuffle = FALSE)


## End(Not run)

mlampros/FeatureSelection documentation built on Jan. 12, 2023, 4:40 a.m.