필터 지우기
필터 지우기

Reding csv file which contains numbers and strings

조회 수: 5 (최근 30일)
MiauMiau
MiauMiau 2014년 11월 27일
댓글: MiauMiau 2014년 11월 27일
Hi
I have a csv file test.csv with some thousands of lines each with three columns in the following style:
Wqckwb Pqbbxx Oq Ptjnfbdqa Gqpqsn Bdqoxfn 519908 519
cms nmyqjnmqsbdqgq pnqqfn g fxtfeqq fqmgqpqsn 411990 411
Unfortunately I can not read the file in with csv - what exactly can I do? Thanks

채택된 답변

dpb
dpb 2014년 11월 27일
Try importdata but it's not absolutely guaranteed. With the regular numeric format it should be able to figure it out.
But, if it can't successfully read the first column as a text header then textscan or fscanf are your friends....
  댓글 수: 1
MiauMiau
MiauMiau 2014년 11월 27일
importdata worked perfectly indeed! thanks so much!!

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Text Files에 대해 자세히 알아보기

태그

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by