Replacement of Structure array field with array
18 ビュー (過去 30 日間)
古いコメントを表示
I have a structure with a field. I want to replace the field value for each element of the structure. I thought that this would work since it returns the values, but it errors out: [S.x] = 1:10
Want to vectorize this: for i = 1:10 S(i).x = i; end
I've seen similar questions, but nothing that seemed to work.
Thanks!
0 件のコメント
採用された回答
その他の回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Structures についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!