how can I determine size of a text or csv file in matlab scripts?

조회 수: 20 (최근 30일)
minomi
minomi 2018년 6월 29일
답변: Nivas Jayaseelan 2019년 1월 21일
I am writing scripts which loop around a large number of ".csv" files and read them, etc. Some of the data files are very small and hence I would like to ignore them. Is there a way I can extract the data file sizes in Matlab scripts? For instance, if I have a file named exmaple.csv which is 2kB, how do I get matlab to output 2kB as the data file size?

채택된 답변

jonas
jonas 2018년 6월 29일
props = dir(filename);
props.bytes
outputs the size of a file

추가 답변 (1개)

Nivas Jayaseelan
Nivas Jayaseelan 2019년 1월 21일
How to print the file size of .pdf..??

카테고리

Help CenterFile Exchange에서 Data Import and Export에 대해 자세히 알아보기

태그

제품


릴리스

R2017b

Community Treasure Hunt

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

Start Hunting!

Translated by