Converting a matrix into an array

How would i convert a matrix into an array, where each column of numbers turns into a single element(matrix)? so all I'm left with is an array with one row and a certain number of columns?

1 件のコメント

Stephen23
Stephen23 2015 年 10 月 6 日
A matrix is an array already, so you either a) don't need to do anything, or b) need to explain in more detail what you are trying to do. Currently your question is not clear.

サインインしてコメントする。

回答 (1 件)

Star Strider
Star Strider 2015 年 10 月 6 日

0 投票

I’m not certain what you want.
Does this work in your application?
A = randi(9, 4); % Matrix
B = A(:)'; % Row Matrix Of Elements Of ‘M’

カテゴリ

ヘルプ センター および File ExchangeMatrices and Arrays についてさらに検索

質問済み:

2015 年 10 月 6 日

コメント済み:

2015 年 10 月 6 日

Community Treasure Hunt

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

Start Hunting!

Translated by