equaling vectors length

조회 수: 2 (최근 30일)
SAM alimostafa
SAM alimostafa 2011년 4월 29일
hi i have two matrices one has size 13x1 and the other is 31x1 and i want to make them equal in length=13x1 is there any function can do that??????

답변 (1개)

Walter Roberson
Walter Roberson 2011년 4월 29일
Here is a code version that will handle any 2D matrices:
S = min(size(A),size(B));
A = A(1:S(1),1:S(2));
B = B(1:S(1),1:S(2));

카테고리

Help CenterFile Exchange에서 Mathematics에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by