MATLAB: Rearrange matrix to vector reaarange matrix Hi! I need to rearrange a matrix A into a vector B as follow: A = [1,2;3,4;5,6] B = [1 2 3 4 5 6] What's the simplest way to do this? Thanks a lot, Knut Best Answer B = reshape(A', 1, []); Related SolutionsMATLAB: Sortrows sortrows(I,-1) MATLAB: Array rearrangement A = A(:); %column-wise extractivonor for more fancy manipulations:doc permutedoc transposedoc reshape Related QuestionRepeat a matrix in defined mannerHow to sort a matrix by a predefined orderFind missing element between two matrixRearranging a Vector Back Again
Best Answer