Description Usage Arguments Value Examples
Getting the pdf of some distribution, where the Const is ignored for MCMC method.
1 2 3 4 5 6 7 |
type |
Type of the distribution one wants to get. c("norm", "mixnorm") is provided. |
... |
Additional arguments for type. |
mu, A |
Parameters for normal distribution, mu being the mean vecter while A being the covariance matrix |
p, m1, mu2, A1, A2 |
Parameters for mixture normal distribution. The pdf can be written as p*pdf1 + (1-p)*pdf2 |
The pdf of 'type'.
1 2 3 4 5 6 7 8 9 | # norm --------------------------------------------------------------------
f <- pdff("norm")
# mixnorm -----------------------------------------------------------------
p <- 0.5
mu1 <- c(0, 0)
mu2 <- c(6, 6)
A1 <- matrix(c(1, 0.1, 0.1, 1), nrow = 2)
A2 <- matrix(c(1, -0.1, -0.1, 1), nrow = 2)
g <- pdff("mixnorm", p, mu1, mu2, A1, A2)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.