using a matrix as an index to another matrix
Ältere Kommentare anzeigen
Simple case:
>> x = [ 10 8 ; 4 3 ]
x =
10 8
4 3
>> [y,i] = sort(x,2 )
y =
8 10
3 4
i =
2 1
2 1
>> x(i)
ans =
4 10
4 10
We see x(i) is not equiv. to y. Can I use x & i to derive y ... ?
Akzeptierte Antwort
Weitere Antworten (1)
Kategorien
Mehr zu Matrix Indexing finden Sie in Hilfe-Center und File Exchange
Produkte
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!