Description Usage Arguments Details Value See Also
Split an object into a training set and a validation set.
1 2 3 4 5 6 7 8 9 10 11 12 13 |
object |
An object to be split. |
split |
A character, numeric variable or a numeric vector declaring a way to split the object. If it's number between 0 and 1, all samples will be split into two subsets randomly, with the trainObj containing such proportion of all samples abd validObj containing the rest. If split is a character and is "bootstrap", the trainObj will be a bootstrap sample of the original data set and the validObj will contain out-of-bag samples. If split is a vector of integers, the trainObj will contain samples whose indice are in the vector, and validObj will contain the rest. |
A function to split the objects into a list of two objects of the same type: one named trainObj and the other named validObj.
Returns a list of two objects of the input type, trainObj and validObj, and the indice of the trainObj.
TrtDataObj-class
TrtDataIdeal-class
wClsObj-class
RegObj-class
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.