Sampling
Sample takes a sample of the specified size from the elements of x using either with or without replacement.
Random Split
If x has length 1, is numeric (in the sense of is.numeric) and x >= 1, sampling via sample takes place from 1:x.

Last modified: 01 October 2025