powered by
Draw a random sample from a probability distribution
random(x, n = 1L, ...)
A probability distribution object such as those created by a call to Bernoulli(), Beta(), or Binomial().
Bernoulli()
Beta()
Binomial()
The number of samples to draw. Should be a positive integer. Defaults to 1L.
1L
Unused. Unevaluated arguments will generate a warning to catch mispellings or other possible errors.
# NOT RUN { X <- Normal() random(X, 10) # }
Run the code above in your browser using DataLab