필터 지우기
필터 지우기

How to access a columns and two or more columns at constat interval and make a sperate matrix?

조회 수: 3 (최근 30일)
A=[1 2 3 4 5 6 7 8 9 11 12 12 14 15 16 17 18 19 20;1 2 3 4 5 6 7 8 9 11 12 12 14 15 16 17 18 19 20;1 2 3 4 5 6 7 8 9 11 12 12 14 15 16 17 18 19 20]
A = 3×19
1 2 3 4 5 6 7 8 9 11 12 12 14 15 16 17 18 19 20 1 2 3 4 5 6 7 8 9 11 12 12 14 15 16 17 18 19 20 1 2 3 4 5 6 7 8 9 11 12 12 14 15 16 17 18 19 20
I need 1st ,6th 11th columns as a matrix and a matrix excluding those columns?

채택된 답변

Matt J
Matt J 2022년 1월 30일
B=A(:,[1,6,11]);
C=A;
C(:,[1,6,11])=[];

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Shifting and Sorting Matrices에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by