필터 지우기
필터 지우기

how to separate points into two vectors from structure

조회 수: 1 (최근 30일)
VANDANA GUPTA
VANDANA GUPTA 2019년 4월 26일
댓글: VANDANA GUPTA 2019년 4월 30일
Target Position Index
1x1 Line [76,76] 76
1x1 Line [71,71] 71
1x1 Line [67,67] 67
1x1 Line [63,63] 63
1x1 Line [59,59] 59
1x1 Line [55,55] 55
1x1 Line [49,49] 49

채택된 답변

Walter Roberson
Walter Roberson 2019년 4월 28일
P1 = arrayfun(@(S) S.Position(1), YourStructure);
P2 = arrayfun(@(S) S.Position(2), YourStructure);
or
pos = vertcat(YourStructure.Position);
P1 = pos(:,1);
P2 = pos(:,2);

추가 답변 (0개)

카테고리

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

Community Treasure Hunt

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

Start Hunting!

Translated by