finding position in matrix
조회 수: 3 (최근 30일)
이전 댓글 표시
I couldnt find the way to figure out how find position M(m,n) matrix can you help me ?
댓글 수: 2
Michael Soskind
2020년 4월 20일
If you want to find a list of positions, you can use:
find(condition)
Where condition might look like M == 1
Alternatively, you could simply use
M == 1
Which would return a logical array of size n x m, meaning that calling M(M==1) would give you a list of the values at the indices above.
Ameer Hamza
2020년 4월 20일
sarp, can you further elaborate your question with an example of what you mean by "find position M(m,n)"?
답변 (1개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Creating and Concatenating Matrices에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!