How to specifically select columns from a matrix?
이전 댓글 표시
Dear All,
For a given 2 columns matrix A. For example

Can I extract the first 3 elements in the 2nd columns and the 4th and 5th elements in the first column by one commend?
I tried the following way but failed: First, I defined an array as follows,

Then I did A(:,r) and it did not work.
Thanks a lot. Bei Gou
채택된 답변
추가 답변 (0개)
카테고리
도움말 센터 및 File Exchange에서 Matrices and Arrays에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!