Dear Rxperts

Below is a small vector of values of zeros and non-zeros... was wondering if
there is an efficient way to get the block sizes of submatrices of a big
matrix similar to the one shown below? diagonal elements can be zero too.
Rows with only a diagonal element may be considered as a unit block size.

c(1,0,0,0,0,0,0,0,0,0,0,
   1,1,0,0,0,0,0,0,0,0,0,
   0,0,1,0,0,0,0,0,0,0,0,
   0,0,0,0,0,0,0,0,0,0,0,
   0,0,0,0,1,0,0,0,0,0,0,
   0,0,0,0,1,1,0,0,0,0,0,
   0,0,0,0,1,1,1,0,0,0,0,
   0,0,0,0,0,0,0,1,0,0,0,
   0,0,0,0,0,0,0,1,1,0,0,
   0,0,0,0,0,0,0,1,1,1,0,
   0,0,0,0,0,0,0,0,0,0,0)

Thanks much!
Santosh

	[[alternative HTML version deleted]]

