STK++ 0.9.13
|
Logistic distribution law. More...
#include <STK_Law_Logistic.h>
Public Types | |
typedef IUnivLaw< Real > | Base |
Public Member Functions | |
Logistic (Real const &mu=0., Real const &scale=1.) | |
Constructor. | |
virtual | ~Logistic () |
Destructor. | |
Real const & | mu () const |
Real const & | scale () const |
void | setMu (Real const &mu) |
void | setScale (Real const &scale) |
Real | rand () const |
Generate a pseudo Logistic random variate. | |
virtual Real | pdf (Real const &x) const |
virtual Real | lpdf (Real const &x) const |
virtual Real | cdf (Real const &t) const |
Compute the cumulative distribution function at t of the standard logistic distribution. | |
virtual Real | icdf (Real const &p) const |
Compute the inverse cumulative distribution function at p of the standard logistic distribution. | |
![]() | |
virtual | ~IUnivLaw () |
Virtual destructor. | |
virtual Real | lcdf (Real const &t) const |
compute the lower tail log-cumulative distribution function Give the log-probability that a random variate is less or equal to t. | |
virtual Real | cdfc (Real const &t) const |
calculate the complement of cumulative distribution function, called in statistics the survival function. | |
virtual Real | lcdfc (Real const &t) const |
calculate the log-complement of cumulative distribution function Give the log-probability that a random variate is greater than t. | |
![]() | |
String const & | name () const |
Static Public Member Functions | |
static Real | rand (Real const &mu, Real const &scale) |
Generate a pseudo Logistic random variate with location mu and scale scale parameters. | |
static Real | pdf (Real const &x, Real const &mu, Real const &scale) |
static Real | lpdf (Real const &x, Real const &mu, Real const &scale) |
static Real | cdf (Real const &t, Real const &mu, Real const &scale) |
static Real | icdf (Real const &p, Real const &mu, Real const &scale) |
Protected Attributes | |
Real | mu_ |
The mu parameter. | |
Real | scale_ |
The scale parameter. | |
![]() | |
String | name_ |
Name of the Law. | |
Additional Inherited Members | |
![]() | |
IUnivLaw (String const &name) | |
Constructor. | |
IUnivLaw (IUnivLaw const &law) | |
copy Constructor. | |
![]() | |
ILawBase (String const &name) | |
Constructor. | |
~ILawBase () | |
destructor. | |
Logistic distribution law.
In probability theory and statistics, the logistic distribution is a continuous probability distribution. Its cumulative distribution function is the logistic function, which appears in logistic regression and feedforward neural networks. It resembles the logistic distribution in shape but has heavier tails (higher kurtosis).
The Logistic distribution with location = m and scale = s>0 has distribution function
and density
It is a long-tailed distribution with mean m and variance
Definition at line 67 of file STK_Law_Logistic.h.
Definition at line 70 of file STK_Law_Logistic.h.
|
inlinevirtual |
Compute the cumulative distribution function at t of the standard logistic distribution.
The cumulative distribution function of the logistic distribution is also a scaled version of the Hyperbolic function.
t | a real value |
Implements STK::Law::IUnivLaw< Real >.
Definition at line 83 of file STK_Law_Logistic.cpp.
t | a real value |
mu,scale | location and scale of the Logistic distribution |
Definition at line 142 of file STK_Law_Logistic.cpp.
Compute the inverse cumulative distribution function at p of the standard logistic distribution.
The inverse cumulative distribution function (quantile function) of the logistic distribution is a generalization of the logit function. It is defined as follows:
p | a probability number. |
Implements STK::Law::IUnivLaw< Real >.
Definition at line 100 of file STK_Law_Logistic.cpp.
p | a probability number. |
mu,scale | location and scale of the Logistic distribution |
Definition at line 153 of file STK_Law_Logistic.cpp.
x | a real value |
Reimplemented from STK::Law::IUnivLaw< Real >.
Definition at line 66 of file STK_Law_Logistic.cpp.
x | a real value |
mu,scale | location and scale of the Logistic distribution |
Definition at line 132 of file STK_Law_Logistic.cpp.
x | a real value |
x
Implements STK::Law::IUnivLaw< Real >.
Definition at line 59 of file STK_Law_Logistic.cpp.
x | a real value |
mu,scale | location and scale of the Logistic distribution |
x
Definition at line 123 of file STK_Law_Logistic.cpp.
|
virtual |
Generate a pseudo Logistic random variate.
Generate a pseudo Logistic random variate with location parameter mu_
and scale scale_
.
Implements STK::Law::IUnivLaw< Real >.
Definition at line 52 of file STK_Law_Logistic.cpp.
Generate a pseudo Logistic random variate with location mu
and scale scale
parameters.
scale scale
parameters.
mu,scale | location and scale of the Logistic distribution |
mu
and with scale scale
Definition at line 114 of file STK_Law_Logistic.cpp.
Definition at line 82 of file STK_Law_Logistic.h.
References scale_.
Referenced by setScale().
scale | the value to set to scale |
Definition at line 86 of file STK_Law_Logistic.h.
References scale(), scale_, setScale(), and STKDOMAIN_ERROR_1ARG.
Referenced by setScale().
|
protected |
The mu parameter.
Definition at line 173 of file STK_Law_Logistic.h.
|
protected |
The scale parameter.
Definition at line 175 of file STK_Law_Logistic.h.
Referenced by scale(), and setScale().