View source: R/utility_functions.R
partition | R Documentation |
Partitions a vector x into n groups of roughly equal size.
partition(x, n)
x |
Vector to partition. |
n |
Number of (roughly) equally-sized groups |
A list of partitions of the vector x.
x <- 1:10 partition( x, 3 )
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.