blkrandomization {Minirand} | R Documentation |
Blocked randomization
Description
The fuction is used to generate treatment assignments based on blocked randomization.
Usage
blkrandomization(n, blocksize, block)
Arguments
n |
numeric number of subjects who will be randomized |
blocksize |
numeric value of block size used for blocked randomization |
block |
vector of treatment blocks used for blocked randomization |
Value
trt a sequence of treatment assignments
Examples
blocksize <- 4
block <- c(1, 2, 3, 4) # treatment 1, 2, 3, 4
n <- 35
blkrandomization(n, blocksize, block)
[Package Minirand version 0.1.3 Index]