Description Usage Arguments Details Value Note Author(s) References See Also Examples

The ex-Gaussian distribution is often used by psychologists to model response time (RT). It is defined by adding two
random variables, one from a normal distribution and the other from an exponential. The parameters `mu`

and
`sigma`

are the mean and standard deviation from the normal distribution variable while the parameter `nu`

is the mean of the exponential variable.
The functions `dexGAUS`

, `pexGAUS`

, `qexGAUS`

and `rexGAUS`

define the density, distribution function,
quantile function and random generation for the ex-Gaussian distribution.

1 2 3 4 5 | ```
exGAUS(mu.link = "identity", sigma.link = "log", nu.link = "log")
dexGAUS(x, mu = 5, sigma = 1, nu = 1, log = FALSE)
pexGAUS(q, mu = 5, sigma = 1, nu = 1, lower.tail = TRUE, log.p = FALSE)
qexGAUS(p, mu = 5, sigma = 1, nu = 1, lower.tail = TRUE, log.p = FALSE)
rexGAUS(n, mu = 5, sigma = 1, nu = 1, ...)
``` |

`mu.link` |
Defines the |

`sigma.link` |
Defines the |

`nu.link` |
Defines the |

`x,q` |
vector of quantiles |

`mu` |
vector of |

`sigma` |
vector of scale parameter values |

`nu` |
vector of |

`log, log.p` |
logical; if TRUE, probabilities p are given as log(p). |

`lower.tail` |
logical; if TRUE (default), probabilities are P[X <= x], otherwise, P[X > x] |

`p` |
vector of probabilities. |

`n` |
number of observations. If |

`...` |
for extra arguments |

The probability density function of the ex-Gaussian distribution, (`exGAUS`

), is defined as

*f(y|mu,sigma,nu)=(1/nu)*exp(((mu-y)/nu)+(sigma^2/(2*nu^2)))*Phi(((y-mu)/sigma)+(sigma/tau))*

where *Phi* is the cdf of the standard normal distribution,
for *-Inf<y<Inf*, *-Inf<mu<Inf*, *σ>0* and *ν>0*.

`exGAUS()`

returns a `gamlss.family`

object which can be used to fit ex-Gaussian distribution in the `gamlss()`

function.
`dexGAUS()`

gives the density, `pexGAUS()`

gives the distribution function,
`qexGAUS()`

gives the quantile function, and `rexGAUS()`

generates random deviates.

The mean of the ex-Gaussian is *mu+nu* and the variance is *sigma^2+nu^2*.

Mikis Stasinopoulos and Bob Rigby

Cousineau, D. Brown, S. and Heathecote A. (2004) Fitting distributions using maximum likelihood: Methods and packages,
*Behavior Research Methods, Instruments and Computers*, **46**, 742-756.

Rigby, R. A. and Stasinopoulos D. M. (2005). Generalized additive models for location, scale and shape,(with discussion),
*Appl. Statist.*, **54**, part 3, pp 507-554.

Rigby, R. A., Stasinopoulos, D. M., Heller, G. Z., and De Bastiani, F. (2019) Distributions for modeling location, scale, and shape: Using GAMLSS in R, Chapman and Hall/CRC. An older version can be found in http://www.gamlss.com/.

Stasinopoulos D. M. Rigby R.A. (2007) Generalized additive models for location scale and shape (GAMLSS) in R.
*Journal of Statistical Software*, Vol. **23**, Issue 7, Dec 2007, http://www.jstatsoft.org/v23/i07.

Stasinopoulos D. M., Rigby R.A., Heller G., Voudouris V., and De Bastiani F., (2017)
*Flexible Regression and Smoothing: Using GAMLSS in R*, Chapman and Hall/CRC.

`gamlss.family`

, `BCCG`

, `GA`

,
`IG`

`LNO`

1 2 3 4 5 6 7 8 9 10 | ```
exGAUS() #
y<- rexGAUS(100, mu=300, nu=100, sigma=35)
hist(y)
# library(gamlss)
# m1<-gamlss(y~1, family=exGAUS)
# plot(m1)
curve(dexGAUS(x, mu=300 ,sigma=35,nu=100), 100, 600,
main = "The ex-GAUS density mu=300 ,sigma=35,nu=100")
plot(function(x) pexGAUS(x, mu=300,sigma=35,nu=100), 100, 600,
main = "The ex-GAUS cdf mu=300, sigma=35, nu=100")
``` |

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.