hi all, sorry for this basic question, I think I know I should use ?apply, but it is really confusing me...

I want to create a matrix by comparing two vectors.  Eg:

test<-seq(1:10)
fac<-c(3,6,9)

and i want to end up with a 10*3 matrix with a boolean that tests if test<fac, so something like:

1 1 1
1 1 1
0 1 1
0 1 1
0 1 1
0 0 1
0 0 1
0 0 1
0 0 0
0 0 0

I can't find the solution without using a loop...

B

	[[alternative HTML version deleted]]

