Questions tagged [empirical-cumulative-distr-fn]

Empirical cumulative distribution function: a step function increasing by $1/n$ at each unique $X$-value that occurred in the sample.

Consider a numeric or at least ordinal random variable $X$ and a random sample of size $n$ from the distribution of $X$, $x_{1}, x_{2}, \dots, x_{n}$. The ECDF $F_{n}(x)$ is a step function increasing by $\frac{1}{n}$ at each unique $X$-value that occurred in the data, when there are no ties. When $k$ values are tied at one value of $x$ the increment is $\frac{k}{n}$. The formal definition is $F_{n}(x) = \frac{1}{n}\sum_{i=1}^{n}I(x_{i} \leq x)$ where $I()$ is the indicator function. (For further explanation, see Integrating an empirical CDF. For a modified estimator of the CDF, visit PIT on a sample with m bins, and KS test used to estimate a good value for m.)

As construction of the ECDF requires no binning, the ECDF is unique and is often a good replacement for a histogram.

153 questions
2
votes
1 answer

Measuring distance between cumulative distribution and empirical distribution

What is an easy to understand step by step procedure on how to compute a distance between a cumulative distribution function and an empirical distribution function given a random sample using Kolmogorov-Smirnov distance. An actual illustrative…
1
vote
0 answers

Proof of empirical expression of Cramer-Von Mises Statistics

I would like to know how to derive the empirical expression of the test statistics below: $$ \omega^2 = \sum_{i=1}^{n}(U_{(i)}-\frac{2i-1}{2n})^2 + \frac{1}{12n} $$ from $$ \omega^2 = n \int_\Omega(F_n(x)-F(x))^2dF(x) $$ I presume that…
0
votes
1 answer

How to inverse the empirical function?

I fitted a empirical distribution to a set of time series data (Y) by following code in R: Ye=rank(Y)/(length(Y)+1) How we can find the inverse of this distribution? Thanks
Fred
  • 1,037