How to Find a Value From Another Value?
조회 수: 3 (최근 30일)
이전 댓글 표시
I have a matrix, so I would like to find a value from the first column by using values from the last columns. For example, I have an specific value from the last column which I found by suing "find". How can I then find the value from the first column from that specific row by using the last column value?
댓글 수: 0
채택된 답변
추가 답변 (1개)
Andrei Bobrov
2017년 12월 7일
편집: Andrei Bobrov
2017년 12월 7일
A = reshape(1:16,4,[]); % Let A - your array (example)
out = A(A(:,end) == 14,1)
댓글 수: 2
참고 항목
카테고리
Help Center 및 File Exchange에서 Matrices and Arrays에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!