How to load a specific element of a variable?
1 回表示 (過去 30 日間)
古いコメントを表示
Hello,
I have a file "Positions.mat" which contains 4 variables: a, b, c, d. Every variable is a 1x2 double.
For example:
a= 1 0.064293
b= 2 0.563890
c= 2 2.475530
d= 1 1.473709
If I load a variable I do
X= load('Positions.mat','a');
But how can I load only the second column of 'a'?
Thank you
0 件のコメント
回答 (1 件)
Walter Roberson
2018 年 2 月 6 日
I would suggest that this is much less efficient than regular access for small to moderate arrays.
0 件のコメント
参考
カテゴリ
Help Center および File Exchange で Workspace Variables and MAT-Files についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!