without using loops
이전 댓글 표시
i have a large scale of data. i need to do the following job without using loops
z=[1,2,3,4;5,18,7,8;12,16,35,-8];
yuk=max(z(:,1:end));
i want to search "yuk" vectors elements in the "z" matrice. but i want to search yuk(1) only for first column of the z matrice , the yuk(2) to the second column of the matrice and so on. how can i do that
thanks
댓글 수: 2
osman
2011년 10월 4일
Andrei Bobrov
2011년 10월 4일
[m n] = size(x)
ind = sub2ind([m n],idx,1:n)
xout = x(ind)
yout = y(ind)
채택된 답변
추가 답변 (1개)
카테고리
도움말 센터 및 File Exchange에서 MATLAB에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!