Hi all
I have a vector like this:
x=[0 0 0 1 1 1 0 0 1 1 0 1 1 1 0 0 0 0 1 1 1 1]
I'm trying to save each part of ones in a Row. for instance, the result of this vector should be a matrix with 4 rows.
1th row = 1 1 12th row = 1 13rd row = 1 1 14th row = 1 1 1 1
how can I do that automatically with a loop.
could you please help me.
Cheers
Best Answer