initMC | R Documentation |
This function initialises the permutation object. It must be called before
nextPerm
can be called
initMC(x)
x |
a vector of integers, reals, logicals or characters |
a object of class mc
which is a list containing elements
mode |
- the mode of the original data in |
set |
- either the multiset being permuted if |
elements |
- if |
length |
- the length of the multiset |
mc |
- a pointer to the internal C++ Multicool object. Users should not use this unless they really know what they are doing |
James M. Curran
nextPerm
x = c(1,1,2,2)
m1 = initMC(x)
m1
## a non-integer example
x = rep(letters[1:4],c(2,1,2,2))
m2 = initMC(x)
m2
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.