matrix reshaping

Does someone know how to reshape an array for example: A=[1 5; 2 4; 5 6] to an array B=(1,6) to be like this: B=[1 5 2 4 5 6];
Thank you...

 採用された回答

bym
bym 2011 年 11 月 17 日

0 投票

reshape(A',1,[])

その他の回答 (2 件)

Honglei Chen
Honglei Chen 2011 年 11 月 17 日

0 投票

You can try
B = A.';
B = B(:).';
athpapa -
athpapa - 2011 年 11 月 17 日

0 投票

thank you very much!

カテゴリ

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

タグ

質問済み:

2011 年 11 月 17 日

Community Treasure Hunt

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

Start Hunting!

Translated by