RandomBlockSizeRandomizer Reference Class
Source:R/class_random_block_size_randomizer.R
RandomBlockSizeRandomizer-class.RdManages random selection of block sizes for randomization procedures. Maintains a reproducible sequence of block sizes using a seed, and provides methods for initialization, value generation, and retrieval.
Fields
seedInteger random seed used for reproducibility.
valuesInteger vector of randomly generated block sizes.
indexInteger index tracking the current position in the values vector.
Methods
- initialize(seed, ...)
Initializes the randomizer with a seed and sets the index to 1.
- show()
Displays a summary of the randomizer.
- toString()
Returns a string representation of the randomizer.
- initRandomValues(numberOfBlockSizes, numberOfValuesToCreate)
Generates a sequence of random block sizes.
- nextInt(numberOfBlockSizes)
Retrieves the next random block size from the sequence.