Mixing and merge two vectors
23 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
Lila wagou
am 23 Mai 2017
Beantwortet: Star Strider
am 23 Mai 2017
Dear all, i want to mix and merge two vector in a one,
A = [1 2 3 4];
B = [5 6 7 8];
to get
C = [1 5 2 6 3 7 4 8];
Thanks in advance
0 Kommentare
Akzeptierte Antwort
Star Strider
am 23 Mai 2017
This works:
A = [1 2 3 4];
B = [5 6 7 8];
C = reshape([A; B], [], 1)';
C =
1 5 2 6 3 7 4 8
0 Kommentare
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Data Types finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!