finding the Column name of a matrix

조회 수: 4 (최근 30일)
galben
galben 2022년 11월 15일
답변: Star Strider 2022년 11월 15일
find the column name correspnding to particular values in a row of a mertrix
i tried this but not working
A(find(A(50,:)=1), 2)

채택된 답변

Star Strider
Star Strider 2022년 11월 15일
I am not certain what you want to do.
The equality comparison operator in MATLAB is the double-equal (==) operator —
A = randi(9, 7, 5)
A = 7×5
2 3 6 7 3 1 6 4 5 9 6 1 8 7 4 9 7 1 7 9 3 1 7 8 7 4 9 2 9 2 7 2 5 5 3
A(find(A(5,:)==1), 2)
ans = 6
.

추가 답변 (0개)

카테고리

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

태그

Community Treasure Hunt

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

Start Hunting!

Translated by