how do you stack (using colon) a 3 dimensional matrix

4 次查看(过去 30 天)
Hi
I have a 3 dimensional matrix A(:,:,K) which I want to stack all the columns per value of K
I haven't found the coding for a 3 dimensional matrix (otherwise I expect to have used B = A(:) which in this case doesn't seem to work

采纳的回答

Walter Roberson
Walter Roberson 2012-6-20
reshape(A, [size(A,1) * size(A,2), size(A,3)])

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Numeric Types 的更多信息

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by