How to convert 4 x 4 matrix into row matrix

I need to convert a 4 x 4 matrix into single row matrix
like
A=[1 2 3 4;
5 6 7 8;
9 10 11 12;
13 14 15 16]
into [1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16]

답변 (1개)

Azzi Abdelmalek
Azzi Abdelmalek 2014년 2월 24일
편집: Azzi Abdelmalek 2014년 2월 24일

0 개 추천

A=A'
A=A(:)'
%Or
reshape(A',1,[])

카테고리

도움말 센터File Exchange에서 Functions에 대해 자세히 알아보기

질문:

2014년 2월 24일

댓글:

2014년 2월 24일

Community Treasure Hunt

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

Start Hunting!

Translated by