MATLAB: Rearrange matrix into single row

MATLAB

Hey there, I have a matrix that looks like this
b=1 2 3 4
1 2 3 4
1 2 3 4
What do I have to do to arrange it into a single row vector[ 1 2 3 4 1 2 3 4 1 2 3 4]?

Best Answer

reshape(b',1,numel(b)) % Note the transpose ('), this is important.