cdfLogistic

Purpose

Computes the cumulative distribution function for the logistic distribution.

Format

p = cdfLogistic(x, loc, scale)
Parameters:
  • x (NxK matrix, Nx1 vector or scalar.) – Values at which to evaluate the cumulative distribution function for the logistic distribution.

  • loc (NxK matrix, Nx1 vector or scalar) – Location parameter, ExE conformable with x.

  • scale (NxK matrix, Nx1 vector or scalar) – Scale parameter; ExE conformable with x. \(0 < scale\).

Returns:

p (NxK matrix, Nx1 vector or scalar) – Each element in p is the cumulative distribution function for the logistic distribution evaluated at the corresponding element in x.

Examples

// Values of interest
x = { 1, 2, 3 };

// Location parameter
loc = 0;

// Scale parameter
s = 2;

p = cdfLogistic(x, loc, s);

After the above code, P will equal:

0.6225
0.7311
0.8176

Remarks

The cumulative distribution function for the logistic distribution is defined as:

\[f(x, \mu, \sigma) = \frac{1}{1 + exp(-z)}\]

where

\[z = \frac{x - \mu}{\sigma}\]

See also

pdfLogistic()