[R] row selection

Ashta
Thu, 08 Oct 2009 20:14:21 -0000

Hi all,
I have a matrix  named x with N by  C
I want to select every 5 th rrow from matrix x
I used the following code
 n<- nrow(x)
> for(i in 1: n){
+ b <- a[i+5,]
>b
}
Error: subscript out of bounds

Can any body point out the problem?

	[[alternative HTML version deleted]]