Exponential Distribution

DESCRIPTION:
Density, cumulative probability, quantiles and random generation for the exponential distribution.

USAGE:
dexp(x, rate=1)
pexp(q, rate=1)
qexp(p, rate=1)
rexp(n, rate=1)

REQUIRED ARGUMENTS:
x:
vector of quantiles. Missing values (NAs) are allowed.
q:
vector of quantiles. Missing values (NAs) are allowed.
p:
vector of probabilities. Missing values (NAs) are allowed.
n:
sample size. If length(n) is larger than 1, then length(n) random values are returned.

OPTIONAL ARGUMENTS:
rate:
the inverse of the mean of the distribution.

VALUE:
density (dexp), probability (pexp), quantile (qexp), or random sample (rexp) for the standard exponential distribution.

SIDE EFFECTS:
The function rexp causes creation of the dataset .Random.seed if it does not already exist, otherwise its value is updated.

DETAILS:
Elements of q or p that are missing will cause the corresponding elements of the result to be missing.

BACKGROUND:
The exponential distribution, a specialization of the gamma distribution (see Gamma), takes on positive real values. A major use of the exponential is in life testing. The exponential has the so called "memoryless property" that the distribution of failure time is the same as the distribution of failure time conditional on having survived to time t.

A relative of the exponential is the double exponential or Laplace distribution. The double exponential is "folded over" so that it is symmetric about zero.


REFERENCES:
Johnson, N. L. and Kotz, S. (1970). Continuous Univariate Distributions, vol. 1 and 2. Houghton-Mifflin, Boston.

SEE ALSO:
set.seed , Gamma , Weibull .

EXAMPLES:
values <- seq(0.0001, 6, length=200); bvals <- values[values>qexp(.95)]
plot(values, dexp(values), type="l")
polygon(c(qexp(.95), bvals, 6), c(0, dexp(bvals), 0))
abline(h=0); abline(v=0)