Description Usage Arguments Value Examples
Density, distribution function, quantile function and random generation for the ex-Gaussian distribution with mean = mu + tau and standard deviation = sigma^{2} + tau^{2}. See Table 1 in Cousineau, Brown, & Heathcote (2004) for the equation.
1 2 3 4 5 6 7 |
x, q |
vector of quantiles. |
mu |
vector of mu parameters. |
sigma |
vector of sigma parameters. |
tau |
vector of tau parameters. |
log, log.p |
logical; if TRUE, probabilities p are given as |
lower.tail |
logical; if TRUE, (default), probabilities are P[X ≤ x] otherwise, P[X > x]. |
p |
vector of probabilities. |
n |
number of observations. |
dexG
gives the density. pexG
gives the distribtuion
function, qexG
gives the quantile function, and rexG
generates
random deviates. sigma < 0 or tau < 0 is an error.
1 2 3 4 5 6 7 8 9 10 11 12 | x <- seq(100, 600, length.out = 1024)
den <- cpda::dexG(x, mu=300, sigma=35, tau=100)
## Use Table 3 in Cousineau, Brown, & Heathcote (2004) as an example
n <- 1024
mu <- 910.56
sigma <- 44.721
tau <- 89.443
sam <- cpda::rexG(n, mu, sigma, tau)
hist(sam, freq = FALSE, breaks = "FD", main = "ex-Gaussian Distribution",
xlab = "RT (ms)", ylab="Density")
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.