Import data from text file and delete blank rows, columns, headers and unnecessary values
2 ビュー (過去 30 日間)
古いコメントを表示
I would like to import useful data only, particularly a 12x11 matrix from the first columns with 12-row zeros to the last columns with 12-row zeros, into Matlab. However my original data file has a lot of blank columns, rows, headers, etc. Can anyone help me in this problem. Thank you very much.
1 件のコメント
回答 (1 件)
Rik
2020 年 6 月 10 日
T=readmatrix('data.txt','NumHeaderLines',4);
T(:,1)=[];%remove row indices in first column
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!