How do I skip every other row of data in an array and write to a text file or another array?
51 ビュー (過去 30 日間)
古いコメントを表示
I have an array (10 x 5 double) that looks like this;
2015 1a 1b 1c 1d
2015 2a 2b 2c 2d
2015 3a 3b 3c 3d
2015 4a 4b 4c 4d
2015 5a 5b 5c 5d
2015 6a 6b 6c 6d
2015 7a 7b 7c 1d
2015 8a 8b 8c 8d
2015 9a 9b 9c 9d
2015 10a 10b 10c 10d
I’m trying to come up with a consistent way to read every 3rd row of data, and then write it to another array or text file. The end result would be an array or text file whose contents look like this:
2015 1a 1b 1c 1d
2015 4a 4b 4c 4d
2015 7a 7b 7c 1d
2015 10a 10b 10c 10d
Any ideas on how to approach this are appreciated.
Thank you.
0 件のコメント
採用された回答
その他の回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Text Files についてさらに検索
製品
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!