hi all,
I have a matrix with first column having some measurable values, these are
indexed by the numerals 1,2 and 3 in the other columns of the data and may
be interpreted as values for categories 1,2 and 3.
I have written the following loop
t<-1:10
 for(i in 1:10)
+ {
+ k[i]<-d[(d[,(i+1)]%in%1),1]
+ p[i]<-d[(d[,(i+1)]%in%2),1]
+ t[i]<-t.test(k[i],p[i])$p.value
+ }
Error in t.test.default(k[i], p[i]) : not enough 'x' observations
In addition: Warning messages:
1: number of items to replace is not a multiple of replacement length
2: number of items to replace is not a multiple of replacement length

As you might have understood, I want to test for difference between the two
cagories: "k" and "v". the second column of the data is the original
categorization and the rest columns(3:10) are a matrix of randomized values
between 1 to 3. (I have three categories)
My purpose of doing so is to check whether significant difference comes up
in the randomized data also. This is to check the effect of the small sample
size of my data.
Please suggest a way or an alternative to the above approach.

	[[alternative HTML version deleted]]

