how do i extract every 10th column from a matrix
3 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
using selectcolumn
1 commentaire
Stephen23
le 5 Sep 2017
@David Craven: what is selectcolumn ?
Why not use very simple and efficient indexing?
Réponses (1)
Star Strider
le 5 Sep 2017
I can’t find a ‘selectcolumn’ function in the online documentation or the File Exchange.
If ‘M’ is your matrix, either:
Out = M(:,[1 10:10:end]);
or:
Out = M(:,1:10:end);
depending on how you define ‘every 10th column’.
0 commentaires
Voir également
Catégories
En savoir plus sur Multidimensional Arrays dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!