rdiric(n, shape, dimension = NULL)
dimension
is specifed, values
are recycled if necessary to length dimension
.dimension
is not numeric then it is taken to be
length(shape)
.n
by dimension
matrix of Dirichlet random variates.
Each element is positive, and each row will sum to unity.dirichlet
is a y <- rdiric(n = 1000, shape = c(3, 1, 4))
fit <- vglm(y ~ 1, dirichlet, trace = TRUE, crit = "c")
Coef(fit)
coef(fit, matrix = TRUE)
Run the code above in your browser using DataLab