Need for assumption of continuity of the distribution In non parametric Inference what is the need to make the assumption that the underlying distribution of the random variable under consideration is absolutely continuous?
 A: Comment continued:  In the real world there is no such thing as
continuous data because we must round observations to some number
of decimal places. The following demonstration shows that the
degree of rounding can influence the results of the 2-sample Wilcoxon
(rank sum) test. 
Originally, data are simulated as two samples of size 20 from Laplace 
distributions with unit scale parameter
and a difference 1.1 between sample means, rounded to 3 places. 
(See 
Wikipedia on Laplace.) There are no ties, so that the data are 'continuous' for purposes of the 
2-sample Wilcoxon test. It finds a significant difference at the 5% level.
set.seed(1234)
x1 = rexp(20) - rexp(20)
x2 = rexp(20) - rexp(20) + 1.1
x = round(c(x1, x2),3)
gp = as.factor(rep(1:2, each=20))
length(unique(x))
[1] 40


wilcox.test(x ~ gp)

        Wilcoxon rank sum test

data:  x by gp
W = 123, p-value = 0.03752
alternative hypothesis: true location shift is not equal to 0

However, if data are rounded to integers, then there are many ties (only 8
uniquely different observations among the 40). Thus, the 2-sample Wilcoxon
test (as implemented in the 'base' of R) fails to reject at the 5% level.
length(unique(round(x)))
[1] 8
wilcox.test(round(x) ~ gp)

        Wilcoxon rank sum test with continuity correction

data:  round(x) by gp
W = 139.5, p-value = 0.09627
alternative hypothesis: true location shift is not equal to 0

Warning message:
In wilcox.test.default(x = c(1, 0, 0, 1, 0, -1, 1, 0, 0, 0, 1, 2,  :
  cannot compute exact p-value with ties

Note: To be fair: the discrepancy in results seen above is not just a matter of ties disturbing the distribution theory of ranks in the Wilcoxon test. The additional rounding to integers results in a serious
loss of information. These are not ideal data for use with t-tests,
but a Welch t test on the original data finds a significant difference
at the 5% level (p-value 0.03) while the a Welch test on integer-rounded data does not
(p-value 0.08). Ordinarily, t tests are much less affected by rounding than are Wilcoxon tests.
