How to compare the length of two matrices and pick the shorter one?
4 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
matlabuser12
am 15 Aug. 2016
Beantwortet: Walter Roberson
am 15 Aug. 2016
have two nx1 matrices that I want to say for whichever matrix is shorter use that length.
0 Kommentare
Akzeptierte Antwort
Walter Roberson
am 15 Aug. 2016
shorter_length = min( length(FirstVector), length(SecondVector) );
0 Kommentare
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Multidimensional Arrays 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!