First occurance problem in the adjacent coloumn
조회 수: 1(최근 30일)
표시 이전 댓글
댓글: Anurag Gupta 2020년 10월 28일
I have a matrix A=[1 9
I want to find out the first occurance of j in coloumn 2 after occurance of i in 1st coloumn at index idx.
i tried idx2 = find(A(idx:end, 2) == j, 'first') but it shows me error Second argument must be a positive scalar integer.
Help is much appreciated thanking in advance.
댓글 수: 0
madhan ravi 2020년 10월 28일
[~, ix1_2] = max(A == [ii, jj])
댓글 수: 1
Find more on Solver Outputs and Iterative Display in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!Start Hunting!