Kolmogorov-Smirnov Distance between Two Distributions. Kolmogorov-Smirnov distance between a discrete distribution with variable probabilities of atoms and a fixed discrete distribution (as function of variable probabilities). This distance is calculated by maximizing deference between two distributions.
Syntax
ksm_max(matrix_kx, vector_yi, vector_qi) |
short call; |
ksm_max_name(matrix_kx, vector_yi, vector_qi) |
call with optional name. |
Parameters
matrix_kx is a PSG matrix:
where the header row contains names of variables. The second row contains numerical data.
vector_yi is a PSG vector:
where the header row contains names of variables. Other rows contain numerical data.
vector_qi is a PSG vector:
where the header row contains names of variables. Other rows contain numerical data.
, .
Mathematical Definition
Kolmogorov-Smirnov distance between Two Distributions function is calculated as follows:
,
where
, is empirical cumulative distribution function defined on the set of unique atoms with vector of probabilities .
, is empirical cumulative distribution function defined on the set of unique atoms with vector of probabilities .
is an argument of function that satisfies the following conditions:
, .
Example
See also
Kolmogorov-Smirnov Distance from a Discrete Distribution to a Mixture of Normal Independent Distributions, CVaR Kolmogorov-Smirnov Distance between Two Distributions, CVaR Kolmogorov-Smirnov Distance from a Discrete Distribution to a Mixture of Normal Independent Distributions , Average Kolmogorov-Smirnov Distance between Two Distributions