powered by
Density of the Dirichlet distribution.
ddirichlet(x, alpha, log = TRUE)
ddirichlet gives the density.
ddirichlet
vector or matrix of quantiles
vector or matrix of shape parameters
logical; if TRUE, densities \(p\) are returned as \(\log(p)\).
TRUE
This implementation of ddirichlet allows for automatic differentiation with RTMB.
RTMB
ddirichlet(c(0.2, 0.3, 0.5), c(1, 2, 3))
Run the code above in your browser using DataLab