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
참고 항목
카테고리
Help Center 및 File Exchange에서 Multidimensional Arrays에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!