Matrix manipulation

조회 수: 2 (최근 30일)
Mate 2u
Mate 2u 2012년 6월 15일
Hi everybody. I have a 2 x 10000 matrix.
I want a short code which can tell me exactly out of the 1000 are [1;1]s?

채택된 답변

Andrei Bobrov
Andrei Bobrov 2012년 6월 15일
A - your matrix
out = sum(ismember(A.',[1 1],'rows')) > 1000;
  댓글 수: 1
Ryan
Ryan 2012년 6월 15일
What is the > 1000 for?

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Resizing and Reshaping Matrices에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by