How can I choose a set of columns from my table. I have to get the means of let's say columns 1 and 5, columns 2 and 6 etc from 20 columns. Thanks
2 ビュー (過去 30 日間)
古いコメントを表示
Does this look like a correct line of code? x = mean(w(:,[1:4:10 11:4:20]));
0 件のコメント
採用された回答
Sadik
2017 年 5 月 26 日
Looks correct. Means of columns 1 and 5, for instance, would look like this:
x = mean(w(:,[1 5]))
Best.
その他の回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Multidimensional Arrays についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!