rdir | R Documentation |
Dirichlet distribution
Title
rdir(n, k)
ddir(x, k, log = FALSE)
n |
number of observations to draw from the Dirichlet distribution |
k |
vector of parameters |
x |
matrix |
log |
logical indicating whether log density should be returned instead. Default FALSE |
returns a matrix of samples from the Dirichlet distribution
with number of rows n for rdir()
or a vector or densities for ddir()
k <- c(3.14, 10.6, 2.24, 8.67)
rdir(20, k)
x <- rdir(5, k)
ddir(x, k)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.