Azzera filtri
Azzera filtri

How can i flip a (M x N) matrix to (N x M)?

13 visualizzazioni (ultimi 30 giorni)
i want to reverse the columns and lines in a matrix how can i do it?

Risposta accettata

Astik Sachan
Astik Sachan il 5 Lug 2017
Modificato: Astik Sachan il 5 Lug 2017
There are two ways to do it:-
A = [1 ,2 ; 3, 4] ;
Flipped_A = transpose(A) ;
2. Put a single-quote to the end of variable
A = [1 ,2 ; 3, 4] ;
Flipped_A = A' ;

Più risposte (1)

Torsten
Torsten il 5 Lug 2017
https://de.mathworks.com/help/matlab/ref/transpose.html
Best wishes
Torsten.

Categorie

Scopri di più su Cell Arrays in Help Center e File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by