Description Usage Arguments Value Examples
generating Cram′er-von Mises test p-value,which the null hypothesis that the two samples come from the same distribution.
1 | cvm(x, y, N)
|
x |
the sample to be tested |
y |
the sample to be tested |
N |
the number of permutation |
Cram′er-von Mise test p-value
1 2 3 4 5 6 7 8 9 10 11 12 | ## Not run:
set.seed(2)
attach(chickwts)
x1 <- sort(as.vector(weight[feed == "soybean"]));
y1 <- sort(as.vector(weight[feed == "linseed"]));
cvm1<-cvm(x1,y1,999);
p1 <- mean(cvm1 >= cvm1[1]);
p1
hist(cvm1, main = "Cramer-von Mises test", freq = FALSE, xlab = "w (p = 0.385)",breaks = "scott");
points(cvm1[1], 0, cex = 1, pch = 16);
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.