データストアを使用し、CSVファイルの指定列、指定行のデータを抽出
조회 수: 13 (최근 30일)
이전 댓글 표시
matlab 2018aを使用しています。
CSVファイルの指定列のデータを抜き出したくてtabularTextDatastoreの
SelectedVariableNamesを使用しています。
さらに指定行のデータを抜き出したいと思ったのですがデータストアを使用して抽出すことはできるのでしょうか。
댓글 수: 0
채택된 답변
Kazuya
2018년 11월 17일
読み取る行に関しては NumHeaderLines プロパティで読み飛ばす行数を設定するか、ReadSize で読み取る行数を決めるくらいしか手段がないですね。ファイルの特定の行だけを読み取るなら、この2つで何とかなりそうですが、どうでしょう?
추가 답변 (1개)
madhan ravi
2018년 11월 17일
Read the while file using readtable() and then you can simply specify as such
T=readtable('mycsv.csv');
T.column %where T is your table and columns is the specific column you need
참고 항목
카테고리
Help Center 및 File Exchange에서 テキスト ファイル에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!