As you haven't posted your data this is indeed a difficult question and posting your data (e.g., via dput()
would make things a lot easier. Other than that we can only specify. See here for more on posing a nice question with a reproducible example.
However, your data has some properties we can see from the summary
that allows for an answer.
Wilcoxon test does seem to be inappropriate for your data. Remember that Wilcoxon uses the rank of each observation. The rank is difficult to obtain as there are ties in the data. You seem to have a lot of ties (min
and median
for c
are both 0
). There are ways to deal with ties, but other methods are better.
As you do seem to not want to use the t-test (reasonable given that the distributions appear to be really different, e.g. median(a) < mean (a)
but median(c) > mean(c)
) another approach would be to use a permutation test.
My package afex
(on CRAN, based on coin
) contains the function compare.2.vectors
comparing two vectors using (e.g.) t-test, Wilcoxon and most notably permutation test. If your n is small, you can even use a exact test distribution for the permutation test. Given two vectors a and c the result could be (trying to simulate your data):
> require(afex)
> a <- round(runif(100, 0, 0.00129), 5)
> c <- c(rep(0, 60), runif(37, 0, 0.00297), rep(1, 3))
> summary(a)
Min. 1st Qu. Median Mean 3rd Qu. Max.
0.0000100 0.0002775 0.0006500 0.0006360 0.0009475 0.0012800
> summary(c)
Min. 1st Qu. Median Mean 3rd Qu. Max.
0.00000 0.00000 0.00000 0.03054 0.00116 1.00000
> compare.2.vectors(a,c)
$parametric
test test.statistic test.value test.df p
1 t t -1.745388 198.00000 0.08246866
2 Welch t -1.745388 99.00094 0.08402002
$nonparametric
test test.statistic test.value test.df p
1 stats::Wilcoxon W 6772.000000 NA 1.143036e-05
2 permutation Z -1.736482 NA 1.929300e-01
3 coin::Wilcoxon Z 4.389418 NA 0.000000e+00
4 median Z -4.514156 NA 0.000000e+00
You see the same pattern, positive test statistics for Wilcoxon, but negative for all other tests. So better not use the Wilcoxon, but one of the other tests, all agreeing.
PS: I am happy for comments on the function. Any more tests that would make sense?