how to extract the string from the struct array

12 ビュー (過去 30 日間)
Shen Jiali
Shen Jiali 2018 年 10 月 5 日
コメント済み: Stephen23 2018 年 10 月 5 日
PSM.name
ans =
'CLOUD13_PSM4_Total_cutoffs_corr_20181001.mat'
ans =
'CLOUD13_PSM4_Total_cutoffs_corr_20181002.mat'
ans =
'CLOUD13_PSM4_Total_cutoffs_corr_20181003.mat'
ans =
'CLOUD13_PSM4_Total_cutoffs_corr_20181004.mat'
I hope I can get the name from the PSM.name one by one by using number,but I already try the PSM.name(1,1);PSM.name{1,1}, neither of them works.

回答 (1 件)

Jos (10584)
Jos (10584) 2018 年 10 月 5 日
I think you have a so-called struct array. Try:
PSM(1).name

カテゴリ

Help Center および File ExchangeStructures についてさらに検索

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by