View source: R/gen_multilevel_data.R
block_distn | R Documentation |
Generate piecewise uniform distribution with a mean of (approximately, due to integer values) n.bar and a 'size.ratio' that controls the variance of site sizes.
block_distn(J, n.bar, size.ratio, min.size = 1, round = TRUE)
J |
number of sites to generate. |
n.bar |
Average site size. |
size.ratio |
Indexes how much variation in block size. size.ratio = 0 means no variation. Higher numbers mean more variation. |
min.size |
Minimum size of each block. |
round |
Round the site sizes to integers? Default of TRUE. (FALSE if want expected sizes or similar.) |
The range of site sizes will be from 1 to n.bar * (1+3*size.ratio).
Numeric vector of site sizes.
block_distn( 4, 10, 1 )
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.