how to sort a cell array based on another cell array
Ältere Kommentare anzeigen
basically i have this cell array:
A = {1,18,2,1,6,8,3,1,1,1}
B = {the,keep,up,run,a,fear,have,tik,love,vik}
basically each element in B have the number of occurances in A, what i need to do is i want to sort A in descendant order ( 18,8,6...) but also i want its corresponding B to sort with it how can i achieve that ?
Akzeptierte Antwort
Weitere Antworten (0)
Kategorien
Mehr zu Shifting and Sorting Matrices finden Sie in Hilfe-Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!