I keep getting the below error:
y <- as.factor(data$Pos.44)
x <- as.factor(data$Neg.44)
wilcox.test( x ~ y,
alternative='two.sided',
paired=FALSE, var.equal = TRUE,
conf.level = 0.95)
Error in wilcox.test.formula(x ~ y, alternative = "two.sided", paired = FALSE, : grouping factor must have exactly 2 levels
I have tried turning the data into factors, as numbers and have told r that the header is TRUE. Any ideas??
Here are some of the data.
Neg 44 Pos 44
13.8228455 7.126694925
13.8228455 8.402648457
13.8228455 8.402648457
6.85288518 12.27621627
9.232427575
11.31157309
195.5120218
82.61317544
9.751455813
4.490663867
7.732335943
3.72520288
17.51041865
8.56912795
17.59120857
12.3571618