set_vector | R Documentation |
Generate a vector of a values from a set
set_vector(size, set = NULL, set_type = NULL, set_size = NULL, ...)
size |
integer, vector length |
set |
vector a set of values to pick from; default: NULL |
set_type |
string if set is NULL generate a random set of type ("integer", "string", "boolean", "numeric"); default: NULL |
set_size |
integer, number of elements in random set; default: NULL |
... |
additional arguments for random set generator.
For details check |
When using a random set, be aware, that set has to be unique, thus if arguments passed to generator do not allow this, the function can end up in an infinite loop.
set_vector(10, set = c("a", "b", "c")) set_vector(size = 5, set_type = "string", set_size = 3)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.