extract the data from 3D struct matrix

3 ビュー (過去 30 日間)
mohammed hussein
mohammed hussein 2017 年 11 月 14 日
コメント済み: mohammed hussein 2017 年 11 月 14 日
Hi i have this matrix in name W attached . this matrix is struct matrix . each element is 1*3. i would like to extract only second number in data cell . for example in cell 1 i want only (3.966836777579012e-08 + 0.000000000000000e+00i) and so on .
thank you very much for helping

採用された回答

KSSV
KSSV 2017 年 11 月 14 日
YOu can extract what you want using:
Extract whole 1X3 matrix:
W(1).data
Extract third number:
W(1).data(3)
To extract whole data:
iwant = [W(:).data] ;
iwant = reshape(iwant,3,[])' ;
  1 件のコメント
mohammed hussein
mohammed hussein 2017 年 11 月 14 日
thank you very much

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeMatrices and Arrays についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by