필터 지우기
필터 지우기

Is there a way to extract specific fields from a structure ?

조회 수: 2 (최근 30일)
laith Farhan
laith Farhan 2018년 7월 11일
댓글: laith Farhan 2018년 7월 11일
Dear all,
I have data as struct , How can I extract the E field into a sperate array? Please see the attachment picture.
I've tried this, but it does not work? ss1(:,rnd)=SN.E; ss1: new array to save the parameter, length (100 x 100) rnd: is a loop from 1 - 100 SN.E: my data that i want to take it in each round.

채택된 답변

Guillaume
Guillaume 2018년 7월 11일
ss1(:, rnd) = [SN.E];
% or
ss1(:, rnd) = vertcat(SN.E);
  댓글 수: 1
laith Farhan
laith Farhan 2018년 7월 11일
Thanks a lot Guillaume, that really helpful . thanks again

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

추가 답변 (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