access properties from an array of objects as an array?

Assume:
  1. obj = an object instance of a class
  2. obj has a property a such that obj.a = <double>
  3. listOfObj = repmat(obj, 10, 1)
I want to search through the set of properties that exists in an array of objects. For example,
find( obj(:).a == 3)
However, that doesn't really work. What are the intelligent approaches?

 채택된 답변

추가 답변 (0개)

카테고리

도움말 센터File Exchange에서 Logical에 대해 자세히 알아보기

제품

릴리스

R2017b

질문:

2018년 6월 20일

댓글:

2018년 6월 21일

Community Treasure Hunt

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

Start Hunting!

Translated by