how do i extract every 10th column from a matrix
3 次查看(过去 30 天)
显示 更早的评论
using selectcolumn
1 个评论
Stephen23
2017-9-5
@David Craven: what is selectcolumn ?
Why not use very simple and efficient indexing?
回答(1 个)
Star Strider
2017-9-5
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 个评论
另请参阅
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!