View source: R/DataSplitting.R
createDefaultSplitSetting | R Documentation |
Create the settings for defining how the plpData are split into test/validation/train sets using default splitting functions (either random stratified by outcome, time or subject splitting)
createDefaultSplitSetting(
testFraction = 0.25,
trainFraction = 0.75,
splitSeed = sample(1e+05, 1),
nfold = 3,
type = "stratified"
)
testFraction |
(numeric) A real number between 0 and 1 indicating the test set fraction of the data |
trainFraction |
(numeric) A real number between 0 and 1 indicating the train set fraction of the data. If not set train is equal to 1 - test |
splitSeed |
(numeric) A seed to use when splitting the data for reproducibility (if not set a random number will be generated) |
nfold |
(numeric) An integer > 1 specifying the number of folds used in cross validation |
type |
(character) Choice of:
|
Returns an object of class splitSettings
that specifies the
splitting function that will be called and the settings
An object of class splitSettings
createDefaultSplitSetting(testFraction=0.25, trainFraction=0.75, nfold=3,
splitSeed=42)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.