View source: R/estimateDirichDist.R
estimateDirichDist | R Documentation |
The parameter estimation is accomplished using a count data
matrix. The estimation is based on the fact that if a variable
x = (x_1, x_2, ...x_n)
follows Dirichlet Distribution with parameters
\alpha = \alpha_1, ... , \alpha_n
(all positive reals), in short,
x ~ Dir(\alpha)
, then x_i ~ Beta(\alpha_i, \alpha_0 - \alpha_i)
,
where Beta(.) stands for the Beta distribution and
\alpha_0 = \sum \alpha_i
.
Dirichlet distribution is a family of continuous multivariate probability distributions, a multivariate generalization of the Beta distribution.
estimateDirichDist(
x,
start = NULL,
num.cores = 1L,
tasks = 0L,
seed = 123,
refit = TRUE,
verbose = TRUE,
...
)
x |
A matrix or a data.frame object carrying count data. |
start |
Initial parameter values for |
num.cores, tasks |
Parameters for parallel computation using
|
verbose |
if TRUE, prints the function log to stdout and a progress bar |
... |
Further arguments for |
As any non-linear fitting, results strongly depends on the start parameter values.
A vector of estimated parameter values
Robersy Sanchez <https://genomaths.com>
betaDistEstimation
and betaBinPost
#' ## A random generation numerical vectors with
x <- rdirichlet(n = 1000, alpha = c(2.1, 3.1, 1.2))
head(x)
estimateDirichDist(x)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.