Density, distribution function, quantile function and random
generation for the logistic distribution with parameters
1 2 3 4
vector of quantiles.
vector of probabilities.
number of observations. If
location and scale parameters.
logical; if TRUE, probabilities p are given as log(p).
logical; if TRUE (default), probabilities are P[X ≤ x], otherwise, P[X > x].
scale are omitted, they assume the
default values of
The Logistic distribution with
location = m and
scale = s has distribution function
F(x) = 1 / (1 + exp(-(x-m)/s))
f(x) = 1/s exp((x-m)/s) (1 + exp((x-m)/s))^-2.
It is a long-tailed distribution with mean m and variance π^2 /3 s^2.
dlogis gives the density,
plogis gives the distribution function,
qlogis gives the quantile function, and
rlogis generates random deviates.
The length of the result is determined by
rlogis, and is the maximum of the lengths of the
numerical arguments for the other functions.
The numerical arguments other than
n are recycled to the
length of the result. Only the first elements of the logical
arguments are used.
qlogis(p) is the same as the well known ‘logit’
function, logit(p) = log(p/(1-p)),
plogis(x) has consequently been called the ‘inverse logit’.
The distribution function is a rescaled hyperbolic tangent,
plogis(x) == (1+ tanh(x/2))/2, and it is called a
sigmoid function in contexts such as neural networks.
[dpq]logis are calculated directly from the definitions.
rlogis uses inversion.
Becker, R. A., Chambers, J. M. and Wilks, A. R. (1988) The New S Language. Wadsworth & Brooks/Cole.
Johnson, N. L., Kotz, S. and Balakrishnan, N. (1995) Continuous Univariate Distributions, volume 2, chapter 23. Wiley, New York.
Distributions for other standard distributions.
Want to suggest features or report bugs for rdrr.io? Use the GitHub issue tracker.