Say I have a matrix a = [1 2 3 4 5 6];, how do I reshape it in a row-wise manner for example reshape(a, 2, 3) to yield
a = [1 2 3 4 5 6];
reshape(a, 2, 3)
1 2 3 4 5 6 >
It is indeed reshape(A',cols,rows)'
( reshape(a', 3, 2)' in your example)