필터 지우기
필터 지우기

How can i read a csv file

조회 수: 4 (최근 30일)
Lisa Justin
Lisa Justin 2012년 10월 15일
How can i read a csv file. i used fopen but it gives a value of -1
A=fopen('slip.csv')

채택된 답변

Walter Roberson
Walter Roberson 2012년 10월 15일
csv files are text files, usually written in ASCII or ISO-8896-1 (which is compatible with ASCII).
  댓글 수: 4
Lisa Justin
Lisa Justin 2012년 10월 18일
thanks
Lisa Justin
Lisa Justin 2012년 10월 18일
Hi Walter, i also want to creat a file list of the large csv data i have. when i write dir *.csv i get all data displayed but when i try to write a script say
dir=('C:\Lisajustin\Vib')
Listdir=sprintf('%d%d',dir, '\*.csv');
i get error message ??? Error using ==> sprintf Function is not defined for 'struct' inputs.
what could be the problem

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

추가 답변 (1개)

Sachin Ganjare
Sachin Ganjare 2012년 10월 16일
You can use 'csvread' function. Refer link below for further details:
Hope it helps!!!

카테고리

Help CenterFile Exchange에서 Low-Level File I/O에 대해 자세히 알아보기

태그

Community Treasure Hunt

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

Start Hunting!

Translated by