MATLAB: Extract submatrix from a large matrix using loop

loop matrix extract small

Dear friends, I have a matrix 1140 by 330. I have to split the matrix into 60 matrices with the size of 19*330 using a for loop. does any one know how to do that?

Best Answer

You can use MAT2TILES ( Download ). For example,
A=rand(1140,330);
C=mat2tiles(A,[19,330]);