Find indices in accumarray syntax
1 visualizzazione (ultimi 30 giorni)
Mostra commenti meno recenti
Oday Shahadh
il 10 Gen 2017
Commentato: Oday Shahadh
il 10 Gen 2017
How can I find the indices in the accumarray syntax below, Thanks in advance
accumarray(OrbNO,elev,[],@(x) max(x)-min(x), 0);
Risposta accettata
Walter Roberson
il 10 Gen 2017
function idx = maxidx(x)
[~, idx] = max(x);
function idx = minidx(x)
[~, idx] = min(x);
Together with
accumarray(OrbNO,elev,[],@(x) maxidx(x)-minidx(x), 0);
0 Commenti
Più risposte (0)
Vedere anche
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!