srswr | R Documentation |
Draws a simple random sampling with replacement of size n (equal probabilities, fixed sample size, with replacement).
srswr(n,N)
n |
sample size. |
N |
population size. |
Returns a vector of size N, the population size. Each element k of this vector indicates the number of replicates of unit k in the sample.
UPmultinomial
s=srswr(3,10)
#the selected units are
which(s!=0)
#with the number of replicates
s[s!=0]
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.